From 4e525bc8b8822e236ab83a6f52a72c05744f6970 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Wed, 10 May 2023 01:14:35 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20post-p?= =?UTF-8?q?rocessor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- .../samples/V2/ApiKeysClient/create_key.php | 10 +- .../samples/V2/ApiKeysClient/delete_key.php | 9 +- ApiKeys/samples/V2/ApiKeysClient/get_key.php | 9 +- .../V2/ApiKeysClient/get_key_string.php | 9 +- .../samples/V2/ApiKeysClient/list_keys.php | 9 +- .../samples/V2/ApiKeysClient/lookup_key.php | 9 +- .../samples/V2/ApiKeysClient/undelete_key.php | 9 +- .../samples/V2/ApiKeysClient/update_key.php | 9 +- .../src/V2/Client/ApiKeysClient.php | 0 .../Client/BaseClient/ApiKeysBaseClient.php | 0 ApiKeys/src/V2/CreateKeyRequest.php | 28 + ApiKeys/src/V2/DeleteKeyRequest.php | 14 + ApiKeys/src/V2/GetKeyRequest.php | 14 + ApiKeys/src/V2/GetKeyStringRequest.php | 14 + ApiKeys/src/V2/ListKeysRequest.php | 14 + ApiKeys/src/V2/UpdateKeyRequest.php | 23 + .../resources/api_keys_descriptor_config.php | 79 + .../Unit/V2/Client/ApiKeysClientTest.php | 0 .../V1/ProvisioningClient/create_instance.php | 11 +- .../V1/ProvisioningClient/delete_instance.php | 9 +- .../V1/ProvisioningClient/get_iam_policy.php | 9 +- .../V1/ProvisioningClient/get_instance.php | 9 +- .../V1/ProvisioningClient/get_location.php | 8 +- .../V1/ProvisioningClient/list_locations.php | 8 +- .../V1/ProvisioningClient/set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../samples/V1/RegistryClient/create_api.php | 11 +- .../RegistryClient/create_api_deployment.php | 15 +- .../V1/RegistryClient/create_api_spec.php | 11 +- .../V1/RegistryClient/create_api_version.php | 11 +- .../V1/RegistryClient/create_artifact.php | 11 +- .../samples/V1/RegistryClient/delete_api.php | 9 +- .../RegistryClient/delete_api_deployment.php | 9 +- .../delete_api_deployment_revision.php | 9 +- .../V1/RegistryClient/delete_api_spec.php | 9 +- .../delete_api_spec_revision.php | 9 +- .../V1/RegistryClient/delete_api_version.php | 9 +- .../V1/RegistryClient/delete_artifact.php | 9 +- .../samples/V1/RegistryClient/get_api.php | 9 +- .../V1/RegistryClient/get_api_deployment.php | 9 +- .../V1/RegistryClient/get_api_spec.php | 9 +- .../RegistryClient/get_api_spec_contents.php | 9 +- .../V1/RegistryClient/get_api_version.php | 9 +- .../V1/RegistryClient/get_artifact.php | 9 +- .../RegistryClient/get_artifact_contents.php | 9 +- .../V1/RegistryClient/get_iam_policy.php | 9 +- .../V1/RegistryClient/get_location.php | 8 +- .../list_api_deployment_revisions.php | 9 +- .../RegistryClient/list_api_deployments.php | 9 +- .../list_api_spec_revisions.php | 9 +- .../V1/RegistryClient/list_api_specs.php | 9 +- .../V1/RegistryClient/list_api_versions.php | 9 +- .../samples/V1/RegistryClient/list_apis.php | 9 +- .../V1/RegistryClient/list_artifacts.php | 9 +- .../V1/RegistryClient/list_locations.php | 8 +- .../V1/RegistryClient/replace_artifact.php | 9 +- .../rollback_api_deployment.php | 10 +- .../V1/RegistryClient/rollback_api_spec.php | 10 +- .../V1/RegistryClient/set_iam_policy.php | 10 +- .../tag_api_deployment_revision.php | 10 +- .../RegistryClient/tag_api_spec_revision.php | 10 +- .../RegistryClient/test_iam_permissions.php | 10 +- .../samples/V1/RegistryClient/update_api.php | 9 +- .../RegistryClient/update_api_deployment.php | 9 +- .../V1/RegistryClient/update_api_spec.php | 9 +- .../V1/RegistryClient/update_api_version.php | 9 +- .../BaseClient/ProvisioningBaseClient.php | 0 .../Client/BaseClient/RegistryBaseClient.php | 0 .../src/V1/Client/ProvisioningClient.php | 0 .../src/V1/Client/RegistryClient.php | 0 .../src/V1/CreateApiDeploymentRequest.php | 25 + ApigeeRegistry/src/V1/CreateApiRequest.php | 25 + .../src/V1/CreateApiSpecRequest.php | 25 + .../src/V1/CreateApiVersionRequest.php | 25 + .../src/V1/CreateArtifactRequest.php | 25 + .../src/V1/CreateInstanceRequest.php | 19 + .../src/V1/DeleteApiDeploymentRequest.php | 15 + .../V1/DeleteApiDeploymentRevisionRequest.php | 18 + ApigeeRegistry/src/V1/DeleteApiRequest.php | 15 + .../src/V1/DeleteApiSpecRequest.php | 15 + .../src/V1/DeleteApiSpecRevisionRequest.php | 18 + .../src/V1/DeleteApiVersionRequest.php | 15 + .../src/V1/DeleteArtifactRequest.php | 15 + .../src/V1/DeleteInstanceRequest.php | 15 + .../src/V1/GetApiDeploymentRequest.php | 15 + ApigeeRegistry/src/V1/GetApiRequest.php | 15 + .../src/V1/GetApiSpecContentsRequest.php | 15 + ApigeeRegistry/src/V1/GetApiSpecRequest.php | 15 + .../src/V1/GetApiVersionRequest.php | 15 + .../src/V1/GetArtifactContentsRequest.php | 15 + ApigeeRegistry/src/V1/GetArtifactRequest.php | 15 + ApigeeRegistry/src/V1/GetInstanceRequest.php | 15 + .../src/V1/ListApiDeploymentsRequest.php | 15 + ApigeeRegistry/src/V1/ListApiSpecsRequest.php | 15 + .../src/V1/ListApiVersionsRequest.php | 15 + ApigeeRegistry/src/V1/ListApisRequest.php | 15 + .../src/V1/ListArtifactsRequest.php | 15 + .../src/V1/ReplaceArtifactRequest.php | 16 + .../src/V1/UpdateApiDeploymentRequest.php | 21 + ApigeeRegistry/src/V1/UpdateApiRequest.php | 21 + .../src/V1/UpdateApiSpecRequest.php | 21 + .../src/V1/UpdateApiVersionRequest.php | 21 + .../provisioning_descriptor_config.php | 84 + .../resources/registry_descriptor_config.php | 474 +++ .../Unit/V1/Client/ProvisioningClientTest.php | 0 .../Unit/V1/Client/RegistryClientTest.php | 0 .../V2/BareMetalSolutionClient/detach_lun.php | 10 +- .../BareMetalSolutionClient/get_instance.php | 9 +- .../V2/BareMetalSolutionClient/get_lun.php | 9 +- .../BareMetalSolutionClient/get_network.php | 9 +- .../BareMetalSolutionClient/get_nfs_share.php | 9 +- .../V2/BareMetalSolutionClient/get_volume.php | 9 +- .../list_instances.php | 9 +- .../V2/BareMetalSolutionClient/list_luns.php | 9 +- .../list_network_usage.php | 9 +- .../BareMetalSolutionClient/list_networks.php | 9 +- .../list_nfs_shares.php | 9 +- .../BareMetalSolutionClient/list_volumes.php | 9 +- .../reset_instance.php | 9 +- .../BareMetalSolutionClient/resize_volume.php | 9 +- .../start_instance.php | 9 +- .../BareMetalSolutionClient/stop_instance.php | 9 +- .../update_instance.php | 9 +- .../update_network.php | 9 +- .../update_nfs_share.php | 9 +- .../BareMetalSolutionClient/update_volume.php | 9 +- .../src/V2/Client/BareMetalSolutionClient.php | 0 .../BareMetalSolutionBaseClient.php | 0 BareMetalSolution/src/V2/DetachLunRequest.php | 17 + .../src/V2/GetInstanceRequest.php | 14 + BareMetalSolution/src/V2/GetLunRequest.php | 14 + .../src/V2/GetNetworkRequest.php | 14 + .../src/V2/GetNfsShareRequest.php | 14 + BareMetalSolution/src/V2/GetVolumeRequest.php | 14 + .../src/V2/ListInstancesRequest.php | 14 + BareMetalSolution/src/V2/ListLunsRequest.php | 14 + .../src/V2/ListNetworkUsageRequest.php | 14 + .../src/V2/ListNetworksRequest.php | 14 + .../src/V2/ListNfsSharesRequest.php | 14 + .../src/V2/ListVolumesRequest.php | 14 + .../src/V2/ResetInstanceRequest.php | 14 + .../src/V2/ResizeVolumeRequest.php | 16 + .../src/V2/StartInstanceRequest.php | 14 + .../src/V2/StopInstanceRequest.php | 14 + .../src/V2/UpdateInstanceRequest.php | 22 + .../src/V2/UpdateNetworkRequest.php | 20 + .../src/V2/UpdateNfsShareRequest.php | 20 + .../src/V2/UpdateVolumeRequest.php | 24 + .../bare_metal_solution_descriptor_config.php | 216 ++ .../V2/Client/BareMetalSolutionClientTest.php | 0 .../V1/BatchServiceClient/create_job.php | 10 +- .../V1/BatchServiceClient/delete_job.php | 8 +- .../samples/V1/BatchServiceClient/get_job.php | 9 +- .../V1/BatchServiceClient/get_location.php | 8 +- .../V1/BatchServiceClient/get_task.php | 9 +- .../V1/BatchServiceClient/list_jobs.php | 8 +- .../V1/BatchServiceClient/list_locations.php | 8 +- .../V1/BatchServiceClient/list_tasks.php | 9 +- .../BaseClient/BatchServiceBaseClient.php | 0 .../src/V1/Client/BatchServiceClient.php | 0 Batch/src/V1/CreateJobRequest.php | 27 + Batch/src/V1/DeleteJobRequest.php | 13 + Batch/src/V1/GetJobRequest.php | 14 + Batch/src/V1/GetTaskRequest.php | 14 + Batch/src/V1/ListJobsRequest.php | 13 + Batch/src/V1/ListTasksRequest.php | 16 + .../batch_service_descriptor_config.php | 91 + .../Unit/V1/Client/BatchServiceClientTest.php | 0 .../create_app_connection.php | 10 +- .../delete_app_connection.php | 9 +- .../get_app_connection.php | 9 +- .../get_iam_policy.php | 9 +- .../get_location.php | 8 +- .../list_app_connections.php | 9 +- .../list_locations.php | 8 +- .../resolve_app_connections.php | 13 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../update_app_connection.php | 10 +- .../V1/Client/AppConnectionsServiceClient.php | 0 .../AppConnectionsServiceBaseClient.php | 0 .../src/V1/CreateAppConnectionRequest.php | 22 + .../src/V1/DeleteAppConnectionRequest.php | 15 + .../src/V1/GetAppConnectionRequest.php | 15 + .../src/V1/ListAppConnectionsRequest.php | 15 + .../src/V1/ResolveAppConnectionsRequest.php | 15 + .../src/V1/UpdateAppConnectionRequest.php | 22 + ..._connections_service_descriptor_config.php | 116 + .../AppConnectionsServiceClientTest.php | 0 .../create_app_connector.php | 10 +- .../delete_app_connector.php | 9 +- .../get_app_connector.php | 9 +- .../get_iam_policy.php | 9 +- .../get_location.php | 8 +- .../list_app_connectors.php | 9 +- .../list_locations.php | 8 +- .../report_status.php | 10 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../update_app_connector.php | 10 +- .../V1/Client/AppConnectorsServiceClient.php | 0 .../AppConnectorsServiceBaseClient.php | 0 .../src/V1/CreateAppConnectorRequest.php | 23 + .../src/V1/DeleteAppConnectorRequest.php | 15 + .../src/V1/GetAppConnectorRequest.php | 15 + .../src/V1/ListAppConnectorsRequest.php | 15 + .../src/V1/ReportStatusRequest.php | 17 + .../src/V1/UpdateAppConnectorRequest.php | 20 + ...p_connectors_service_descriptor_config.php | 113 + .../Client/AppConnectorsServiceClientTest.php | 0 .../create_app_gateway.php | 10 +- .../delete_app_gateway.php | 9 +- .../get_app_gateway.php | 9 +- .../get_iam_policy.php | 9 +- .../AppGatewaysServiceClient/get_location.php | 8 +- .../list_app_gateways.php | 9 +- .../list_locations.php | 8 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../V1/Client/AppGatewaysServiceClient.php | 0 .../AppGatewaysServiceBaseClient.php | 0 .../src/V1/CreateAppGatewayRequest.php | 22 + .../src/V1/DeleteAppGatewayRequest.php | 15 + .../src/V1/GetAppGatewayRequest.php | 15 + .../src/V1/ListAppGatewaysRequest.php | 15 + ...app_gateways_service_descriptor_config.php | 94 + .../Client/AppGatewaysServiceClientTest.php | 0 .../create_client_connector_service.php | 13 +- .../delete_client_connector_service.php | 9 +- .../get_client_connector_service.php | 9 +- .../get_iam_policy.php | 9 +- .../get_location.php | 8 +- .../list_client_connector_services.php | 9 +- .../list_locations.php | 8 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../update_client_connector_service.php | 13 +- ...ientConnectorServicesServiceBaseClient.php | 0 .../ClientConnectorServicesServiceClient.php | 0 .../CreateClientConnectorServiceRequest.php | 24 + .../DeleteClientConnectorServiceRequest.php | 14 + .../V1/GetClientConnectorServiceRequest.php | 14 + .../V1/ListClientConnectorServicesRequest.php | 14 + .../UpdateClientConnectorServiceRequest.php | 21 + ...tor_services_service_descriptor_config.php | 104 + ...ientConnectorServicesServiceClientTest.php | 0 .../create_client_gateway.php | 10 +- .../delete_client_gateway.php | 9 +- .../get_client_gateway.php | 9 +- .../get_iam_policy.php | 9 +- .../get_location.php | 8 +- .../list_client_gateways.php | 9 +- .../list_locations.php | 8 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../ClientGatewaysServiceBaseClient.php | 0 .../V1/Client/ClientGatewaysServiceClient.php | 0 .../src/V1/CreateClientGatewayRequest.php | 21 + .../src/V1/DeleteClientGatewayRequest.php | 14 + .../src/V1/GetClientGatewayRequest.php | 14 + .../src/V1/ListClientGatewaysRequest.php | 14 + ...ent_gateways_service_descriptor_config.php | 94 + .../ClientGatewaysServiceClientTest.php | 0 .../create_data_exchange.php | 15 +- .../create_listing.php | 11 +- .../delete_data_exchange.php | 9 +- .../delete_listing.php | 9 +- .../get_data_exchange.php | 9 +- .../get_iam_policy.php | 9 +- .../AnalyticsHubServiceClient/get_listing.php | 9 +- .../list_data_exchanges.php | 9 +- .../list_listings.php | 9 +- .../list_org_data_exchanges.php | 9 +- .../set_iam_policy.php | 10 +- .../subscribe_listing.php | 9 +- .../test_iam_permissions.php | 10 +- .../update_data_exchange.php | 10 +- .../update_listing.php | 10 +- .../V1/Client/AnalyticsHubServiceClient.php | 0 .../AnalyticsHubServiceBaseClient.php | 0 .../src/V1/CreateDataExchangeRequest.php | 17 + .../src/V1/CreateListingRequest.php | 17 + .../src/V1/DeleteDataExchangeRequest.php | 15 + .../src/V1/DeleteListingRequest.php | 15 + .../src/V1/GetDataExchangeRequest.php | 15 + .../src/V1/GetListingRequest.php | 15 + .../src/V1/ListDataExchangesRequest.php | 15 + .../src/V1/ListListingsRequest.php | 15 + .../src/V1/ListOrgDataExchangesRequest.php | 14 + .../src/V1/SubscribeListingRequest.php | 15 + .../src/V1/UpdateDataExchangeRequest.php | 17 + .../src/V1/UpdateListingRequest.php | 17 + ...nalytics_hub_service_descriptor_config.php | 182 ++ .../Client/AnalyticsHubServiceClientTest.php | 0 .../create_data_exchange.php | 15 +- .../create_listing.php | 11 +- .../delete_data_exchange.php | 9 +- .../delete_listing.php | 9 +- .../get_data_exchange.php | 9 +- .../get_iam_policy.php | 9 +- .../AnalyticsHubServiceClient/get_listing.php | 9 +- .../get_location.php | 8 +- .../list_data_exchanges.php | 9 +- .../list_listings.php | 9 +- .../list_locations.php | 8 +- .../list_org_data_exchanges.php | 9 +- .../set_iam_policy.php | 10 +- .../subscribe_listing.php | 9 +- .../test_iam_permissions.php | 10 +- .../update_data_exchange.php | 10 +- .../update_listing.php | 10 +- .../Client/AnalyticsHubServiceClient.php | 0 .../AnalyticsHubServiceBaseClient.php | 0 .../src/V1beta1/CreateDataExchangeRequest.php | 17 + .../src/V1beta1/CreateListingRequest.php | 17 + .../src/V1beta1/DeleteDataExchangeRequest.php | 15 + .../src/V1beta1/DeleteListingRequest.php | 15 + .../src/V1beta1/GetDataExchangeRequest.php | 15 + .../src/V1beta1/GetListingRequest.php | 15 + .../src/V1beta1/ListDataExchangesRequest.php | 15 + .../src/V1beta1/ListListingsRequest.php | 15 + .../V1beta1/ListOrgDataExchangesRequest.php | 14 + .../src/V1beta1/SubscribeListingRequest.php | 15 + .../src/V1beta1/UpdateDataExchangeRequest.php | 17 + .../src/V1beta1/UpdateListingRequest.php | 17 + ...nalytics_hub_service_descriptor_config.php | 202 ++ .../Client/AnalyticsHubServiceClientTest.php | 0 .../create_data_policy.php | 10 +- .../delete_data_policy.php | 9 +- .../get_data_policy.php | 9 +- .../get_iam_policy.php | 9 +- .../list_data_policies.php | 9 +- .../rename_data_policy.php | 10 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../update_data_policy.php | 9 +- .../DataPolicyServiceBaseClient.php | 0 .../src/V1/Client/DataPolicyServiceClient.php | 0 .../src/V1/CreateDataPolicyRequest.php | 18 + .../src/V1/DeleteDataPolicyRequest.php | 15 + .../src/V1/GetDataPolicyRequest.php | 15 + .../src/V1/ListDataPoliciesRequest.php | 15 + .../src/V1/RenameDataPolicyRequest.php | 16 + .../src/V1/UpdateDataPolicyRequest.php | 23 + .../data_policy_service_descriptor_config.php | 111 + .../V1/Client/DataPolicyServiceClientTest.php | 0 .../create_migration_workflow.php | 10 +- .../delete_migration_workflow.php | 9 +- .../get_migration_subtask.php | 9 +- .../get_migration_workflow.php | 9 +- .../list_migration_subtasks.php | 9 +- .../list_migration_workflows.php | 9 +- .../start_migration_workflow.php | 9 +- .../BaseClient/MigrationServiceBaseClient.php | 0 .../src/V2/Client/MigrationServiceClient.php | 0 .../src/V2/CreateMigrationWorkflowRequest.php | 17 + .../src/V2/DeleteMigrationWorkflowRequest.php | 15 + .../src/V2/GetMigrationSubtaskRequest.php | 15 + .../src/V2/GetMigrationWorkflowRequest.php | 15 + .../src/V2/ListMigrationSubtasksRequest.php | 15 + .../src/V2/ListMigrationWorkflowsRequest.php | 15 + .../src/V2/StartMigrationWorkflowRequest.php | 15 + .../migration_service_descriptor_config.php | 85 + .../V2/Client/MigrationServiceClientTest.php | 0 .../batch_create_repositories.php | 10 +- .../create_connection.php | 15 +- .../create_repository.php | 15 +- .../delete_connection.php | 9 +- .../delete_repository.php | 9 +- .../fetch_linkable_repositories.php | 9 +- .../fetch_read_token.php | 9 +- .../fetch_read_write_token.php | 9 +- .../get_connection.php | 9 +- .../get_iam_policy.php | 9 +- .../get_repository.php | 9 +- .../list_connections.php | 9 +- .../list_repositories.php | 9 +- .../set_iam_policy.php | 10 +- .../test_iam_permissions.php | 10 +- .../update_connection.php | 9 +- .../src/V2/BatchCreateRepositoriesRequest.php | 19 + .../RepositoryManagerBaseClient.php | 0 .../src/V2/Client/RepositoryManagerClient.php | 0 Build/src/V2/CreateConnectionRequest.php | 22 + Build/src/V2/CreateRepositoryRequest.php | 23 + Build/src/V2/DeleteConnectionRequest.php | 15 + Build/src/V2/DeleteRepositoryRequest.php | 15 + Build/src/V2/FetchReadTokenRequest.php | 15 + Build/src/V2/FetchReadWriteTokenRequest.php | 15 + Build/src/V2/GetConnectionRequest.php | 15 + Build/src/V2/GetRepositoryRequest.php | 15 + Build/src/V2/ListConnectionsRequest.php | 15 + Build/src/V2/ListRepositoriesRequest.php | 15 + Build/src/V2/UpdateConnectionRequest.php | 15 + .../repository_manager_descriptor_config.php | 170 + .../V2/Client/RepositoryManagerClientTest.php | 0 .../create_certificate.php | 15 +- .../create_certificate_issuance_config.php | 15 +- .../create_certificate_map.php | 15 +- .../create_certificate_map_entry.php | 15 +- .../create_dns_authorization.php | 15 +- .../delete_certificate.php | 9 +- .../delete_certificate_issuance_config.php | 9 +- .../delete_certificate_map.php | 9 +- .../delete_certificate_map_entry.php | 9 +- .../delete_dns_authorization.php | 9 +- .../get_certificate.php | 9 +- .../get_certificate_issuance_config.php | 9 +- .../get_certificate_map.php | 9 +- .../get_certificate_map_entry.php | 9 +- .../get_dns_authorization.php | 9 +- .../CertificateManagerClient/get_location.php | 8 +- .../list_certificate_issuance_configs.php | 9 +- .../list_certificate_map_entries.php | 9 +- .../list_certificate_maps.php | 9 +- .../list_certificates.php | 9 +- .../list_dns_authorizations.php | 9 +- .../list_locations.php | 8 +- .../update_certificate.php | 10 +- .../update_certificate_map.php | 10 +- .../update_certificate_map_entry.php | 10 +- .../update_dns_authorization.php | 10 +- .../CertificateManagerBaseClient.php | 0 .../V1/Client/CertificateManagerClient.php | 0 ...CreateCertificateIssuanceConfigRequest.php | 19 + .../V1/CreateCertificateMapEntryRequest.php | 19 + .../src/V1/CreateCertificateMapRequest.php | 19 + .../src/V1/CreateCertificateRequest.php | 19 + .../src/V1/CreateDnsAuthorizationRequest.php | 19 + ...DeleteCertificateIssuanceConfigRequest.php | 15 + .../V1/DeleteCertificateMapEntryRequest.php | 15 + .../src/V1/DeleteCertificateMapRequest.php | 15 + .../src/V1/DeleteCertificateRequest.php | 15 + .../src/V1/DeleteDnsAuthorizationRequest.php | 15 + .../GetCertificateIssuanceConfigRequest.php | 15 + .../src/V1/GetCertificateMapEntryRequest.php | 15 + .../src/V1/GetCertificateMapRequest.php | 15 + .../src/V1/GetCertificateRequest.php | 15 + .../src/V1/GetDnsAuthorizationRequest.php | 15 + .../ListCertificateIssuanceConfigsRequest.php | 15 + .../V1/ListCertificateMapEntriesRequest.php | 16 + .../src/V1/ListCertificateMapsRequest.php | 15 + .../src/V1/ListCertificatesRequest.php | 15 + .../src/V1/ListDnsAuthorizationsRequest.php | 15 + .../V1/UpdateCertificateMapEntryRequest.php | 17 + .../src/V1/UpdateCertificateMapRequest.php | 17 + .../src/V1/UpdateCertificateRequest.php | 17 + .../src/V1/UpdateDnsAuthorizationRequest.php | 17 + .../certificate_manager_descriptor_config.php | 269 ++ .../Client/CertificateManagerClientTest.php | 0 .../create_challenge.php | 10 +- .../get_location.php | 8 +- .../list_locations.php | 8 +- .../verify_attestation.php | 10 +- .../ConfidentialComputingBaseClient.php | 0 .../V1/Client/ConfidentialComputingClient.php | 0 .../src/V1/CreateChallengeRequest.php | 18 + ...nfidential_computing_descriptor_config.php | 48 + .../ConfidentialComputingClientTest.php | 0 .../batch_search_link_processes.php | 10 +- .../V1/LineageClient/create_lineage_event.php | 10 +- .../V1/LineageClient/create_process.php | 10 +- .../samples/V1/LineageClient/create_run.php | 10 +- .../V1/LineageClient/delete_lineage_event.php | 9 +- .../V1/LineageClient/delete_process.php | 9 +- .../samples/V1/LineageClient/delete_run.php | 9 +- .../V1/LineageClient/get_lineage_event.php | 9 +- .../samples/V1/LineageClient/get_process.php | 9 +- .../samples/V1/LineageClient/get_run.php | 9 +- .../V1/LineageClient/list_lineage_events.php | 9 +- .../V1/LineageClient/list_processes.php | 9 +- .../samples/V1/LineageClient/list_runs.php | 9 +- .../samples/V1/LineageClient/search_links.php | 9 +- .../V1/LineageClient/update_process.php | 9 +- .../samples/V1/LineageClient/update_run.php | 9 +- .../Client/BaseClient/LineageBaseClient.php | 0 .../src/V1/Client/LineageClient.php | 0 .../src/V1/CreateLineageEventRequest.php | 16 + .../src/V1/CreateProcessRequest.php | 17 + .../src/V1/CreateRunRequest.php | 16 + .../src/V1/DeleteLineageEventRequest.php | 14 + .../src/V1/DeleteProcessRequest.php | 14 + .../src/V1/DeleteRunRequest.php | 14 + .../src/V1/GetLineageEventRequest.php | 14 + .../src/V1/GetProcessRequest.php | 14 + DataCatalogLineage/src/V1/GetRunRequest.php | 14 + .../src/V1/ListLineageEventsRequest.php | 14 + .../src/V1/ListProcessesRequest.php | 15 + DataCatalogLineage/src/V1/ListRunsRequest.php | 14 + .../src/V1/UpdateProcessRequest.php | 18 + .../src/V1/UpdateRunRequest.php | 21 + .../resources/lineage_descriptor_config.php | 184 ++ .../Unit/V1/Client/LineageClientTest.php | 0 .../V1/DataFusionClient/create_instance.php | 10 +- .../V1/DataFusionClient/delete_instance.php | 9 +- .../V1/DataFusionClient/get_instance.php | 9 +- .../list_available_versions.php | 9 +- .../V1/DataFusionClient/list_instances.php | 9 +- .../V1/DataFusionClient/restart_instance.php | 9 +- .../V1/DataFusionClient/update_instance.php | 9 +- .../BaseClient/DataFusionBaseClient.php | 0 .../src/V1/Client/DataFusionClient.php | 0 DataFusion/src/V1/CreateInstanceRequest.php | 19 + DataFusion/src/V1/DeleteInstanceRequest.php | 15 + .../src/V1/ListAvailableVersionsRequest.php | 15 + DataFusion/src/V1/UpdateInstanceRequest.php | 22 + .../data_fusion_descriptor_config.php | 74 + .../Unit/V1/Client/DataFusionClientTest.php | 0 .../create_annotation_spec_set.php | 13 +- .../create_dataset.php | 10 +- .../create_evaluation_job.php | 10 +- .../create_instruction.php | 10 +- .../delete_annotated_dataset.php | 9 +- .../delete_annotation_spec_set.php | 9 +- .../delete_dataset.php | 9 +- .../delete_evaluation_job.php | 9 +- .../delete_instruction.php | 9 +- .../DataLabelingServiceClient/export_data.php | 15 +- .../get_annotated_dataset.php | 9 +- .../get_annotation_spec_set.php | 9 +- .../get_data_item.php | 9 +- .../DataLabelingServiceClient/get_dataset.php | 9 +- .../get_evaluation.php | 9 +- .../get_evaluation_job.php | 9 +- .../DataLabelingServiceClient/get_example.php | 9 +- .../get_instruction.php | 9 +- .../DataLabelingServiceClient/import_data.php | 10 +- .../DataLabelingServiceClient/label_image.php | 11 +- .../DataLabelingServiceClient/label_text.php | 11 +- .../DataLabelingServiceClient/label_video.php | 11 +- .../list_annotated_datasets.php | 9 +- .../list_annotation_spec_sets.php | 9 +- .../list_data_items.php | 9 +- .../list_datasets.php | 9 +- .../list_evaluation_jobs.php | 9 +- .../list_examples.php | 9 +- .../list_instructions.php | 9 +- .../pause_evaluation_job.php | 9 +- .../resume_evaluation_job.php | 9 +- .../search_evaluations.php | 9 +- .../search_example_comparisons.php | 9 +- .../update_evaluation_job.php | 9 +- .../DataLabelingServiceBaseClient.php | 0 .../Client/DataLabelingServiceClient.php | 0 .../CreateAnnotationSpecSetRequest.php | 19 + .../src/V1beta1/CreateDatasetRequest.php | 17 + .../V1beta1/CreateEvaluationJobRequest.php | 17 + .../src/V1beta1/CreateInstructionRequest.php | 17 + .../DeleteAnnotationSpecSetRequest.php | 15 + .../src/V1beta1/DeleteDatasetRequest.php | 15 + .../V1beta1/DeleteEvaluationJobRequest.php | 16 + .../src/V1beta1/DeleteInstructionRequest.php | 15 + .../src/V1beta1/ExportDataRequest.php | 26 + .../V1beta1/GetAnnotatedDatasetRequest.php | 16 + .../V1beta1/GetAnnotationSpecSetRequest.php | 15 + .../src/V1beta1/GetDataItemRequest.php | 15 + .../src/V1beta1/GetDatasetRequest.php | 15 + .../src/V1beta1/GetEvaluationJobRequest.php | 16 + .../src/V1beta1/GetEvaluationRequest.php | 16 + .../src/V1beta1/GetExampleRequest.php | 20 + .../src/V1beta1/GetInstructionRequest.php | 15 + .../src/V1beta1/ImportDataRequest.php | 17 + .../src/V1beta1/LabelImageRequest.php | 20 + DataLabeling/src/V1beta1/LabelTextRequest.php | 20 + .../src/V1beta1/LabelVideoRequest.php | 20 + .../V1beta1/ListAnnotatedDatasetsRequest.php | 17 + .../V1beta1/ListAnnotationSpecSetsRequest.php | 17 + .../src/V1beta1/ListDataItemsRequest.php | 17 + .../src/V1beta1/ListDatasetsRequest.php | 17 + .../src/V1beta1/ListEvaluationJobsRequest.php | 24 + .../src/V1beta1/ListExamplesRequest.php | 19 + .../src/V1beta1/ListInstructionsRequest.php | 17 + .../src/V1beta1/PauseEvaluationJobRequest.php | 16 + .../V1beta1/ResumeEvaluationJobRequest.php | 16 + .../src/V1beta1/SearchEvaluationsRequest.php | 47 + .../SearchExampleComparisonsRequest.php | 17 + .../V1beta1/UpdateEvaluationJobRequest.php | 23 + ...ata_labeling_service_descriptor_config.php | 384 +++ .../Client/DataLabelingServiceClientTest.php | 0 .../launch_flex_template.php | 8 +- .../aggregated_list_jobs.php | 8 +- .../JobsV1Beta3Client/check_active_jobs.php | 8 +- .../V1beta3/JobsV1Beta3Client/create_job.php | 8 +- .../V1beta3/JobsV1Beta3Client/get_job.php | 8 +- .../V1beta3/JobsV1Beta3Client/list_jobs.php | 8 +- .../JobsV1Beta3Client/snapshot_job.php | 8 +- .../V1beta3/JobsV1Beta3Client/update_job.php | 8 +- .../list_job_messages.php | 8 +- .../get_job_execution_details.php | 8 +- .../MetricsV1Beta3Client/get_job_metrics.php | 8 +- .../get_stage_execution_details.php | 8 +- .../delete_snapshot.php | 8 +- .../SnapshotsV1Beta3Client/get_snapshot.php | 8 +- .../SnapshotsV1Beta3Client/list_snapshots.php | 8 +- .../create_job_from_template.php | 8 +- .../TemplatesServiceClient/get_template.php | 8 +- .../launch_template.php | 8 +- .../FlexTemplatesServiceBaseClient.php | 0 .../BaseClient/JobsV1Beta3BaseClient.php | 0 .../BaseClient/MessagesV1Beta3BaseClient.php | 0 .../BaseClient/MetricsV1Beta3BaseClient.php | 0 .../BaseClient/SnapshotsV1Beta3BaseClient.php | 0 .../BaseClient/TemplatesServiceBaseClient.php | 0 .../Client/FlexTemplatesServiceClient.php | 0 .../src/V1beta3/Client/JobsV1Beta3Client.php | 0 .../V1beta3/Client/MessagesV1Beta3Client.php | 0 .../V1beta3/Client/MetricsV1Beta3Client.php | 0 .../V1beta3/Client/SnapshotsV1Beta3Client.php | 0 .../V1beta3/Client/TemplatesServiceClient.php | 0 ...ex_templates_service_descriptor_config.php | 21 +- .../jobs_v1_beta3_descriptor_config.php | 120 + .../messages_v1_beta3_descriptor_config.php | 22 + .../metrics_v1_beta3_descriptor_config.php | 74 + .../snapshots_v1_beta3_descriptor_config.php | 75 +- .../templates_service_descriptor_config.php | 57 +- .../Client/FlexTemplatesServiceClientTest.php | 0 .../V1beta3/Client/JobsV1Beta3ClientTest.php | 0 .../Client/MessagesV1Beta3ClientTest.php | 0 .../Client/MetricsV1Beta3ClientTest.php | 0 .../Client/SnapshotsV1Beta3ClientTest.php | 0 .../Client/TemplatesServiceClientTest.php | 0 .../Google/Api/Apikeys/V2/Apikeys.php | 85 - .../Google/Api/Apikeys/V2/Resources.php | Bin 2368 -> 0 bytes .../Cloud/ApiKeys/V2/AndroidApplication.php | 113 - .../ApiKeys/V2/AndroidKeyRestrictions.php | 71 - .../Cloud/ApiKeys/V2/ApiKeysGrpcClient.php | 184 -- .../src/Google/Cloud/ApiKeys/V2/ApiTarget.php | 142 - .../ApiKeys/V2/BrowserKeyRestrictions.php | 71 - .../Cloud/ApiKeys/V2/CreateKeyRequest.php | 205 -- .../Cloud/ApiKeys/V2/DeleteKeyRequest.php | 119 - .../Google/Cloud/ApiKeys/V2/GetKeyRequest.php | 81 - .../Cloud/ApiKeys/V2/GetKeyStringRequest.php | 81 - .../Cloud/ApiKeys/V2/GetKeyStringResponse.php | 67 - .../Cloud/ApiKeys/V2/IosKeyRestrictions.php | 67 - .../proto/src/Google/Cloud/ApiKeys/V2/Key.php | 477 --- .../Cloud/ApiKeys/V2/ListKeysRequest.php | 187 -- .../Cloud/ApiKeys/V2/ListKeysResponse.php | 101 - .../Cloud/ApiKeys/V2/LookupKeyRequest.php | 67 - .../Cloud/ApiKeys/V2/LookupKeyResponse.php | 105 - .../Google/Cloud/ApiKeys/V2/Restrictions.php | 220 -- .../ApiKeys/V2/ServerKeyRestrictions.php | 71 - .../Cloud/ApiKeys/V2/UndeleteKeyRequest.php | 67 - .../Cloud/ApiKeys/V2/UpdateKeyRequest.php | 176 - .../samples/V2/ApiKeysClient/create_key.php | 88 - .../samples/V2/ApiKeysClient/delete_key.php | 87 - .../v2/samples/V2/ApiKeysClient/get_key.php | 75 - .../V2/ApiKeysClient/get_key_string.php | 74 - .../v2/samples/V2/ApiKeysClient/list_keys.php | 80 - .../samples/V2/ApiKeysClient/lookup_key.php | 74 - .../samples/V2/ApiKeysClient/undelete_key.php | 86 - .../samples/V2/ApiKeysClient/update_key.php | 75 - .../ApiKeys/v2/src/V2/ApiKeysClient.php | 34 - .../v2/src/V2/Gapic/ApiKeysGapicClient.php | 859 ----- .../ApiKeys/v2/src/V2/gapic_metadata.json | 58 - .../V2/resources/api_keys_client_config.json | 72 - .../resources/api_keys_descriptor_config.php | 137 - .../resources/api_keys_rest_client_config.php | 107 - .../v2/tests/Unit/V2/ApiKeysClientTest.php | 838 ----- .../Apigeeregistry/V1/ProvisioningService.php | Bin 3297 -> 0 bytes .../Apigeeregistry/V1/RegistryModels.php | 127 - .../Apigeeregistry/V1/RegistryService.php | 235 -- .../Google/Cloud/ApigeeRegistry/V1/Api.php | 458 --- .../Cloud/ApigeeRegistry/V1/ApiDeployment.php | 623 ---- .../Cloud/ApigeeRegistry/V1/ApiSpec.php | 658 ---- .../Cloud/ApigeeRegistry/V1/ApiVersion.php | 386 --- .../Cloud/ApigeeRegistry/V1/Artifact.php | 334 -- .../V1/CreateApiDeploymentRequest.php | 190 -- .../ApigeeRegistry/V1/CreateApiRequest.php | 190 -- .../V1/CreateApiSpecRequest.php | 190 -- .../V1/CreateApiVersionRequest.php | 190 -- .../V1/CreateArtifactRequest.php | 190 -- .../V1/CreateInstanceRequest.php | 168 - .../V1/DeleteApiDeploymentRequest.php | 124 - .../V1/DeleteApiDeploymentRevisionRequest.php | 97 - .../ApigeeRegistry/V1/DeleteApiRequest.php | 124 - .../V1/DeleteApiSpecRequest.php | 124 - .../V1/DeleteApiSpecRevisionRequest.php | 97 - .../V1/DeleteApiVersionRequest.php | 124 - .../V1/DeleteArtifactRequest.php | 86 - .../V1/DeleteInstanceRequest.php | 86 - .../V1/GetApiDeploymentRequest.php | 86 - .../Cloud/ApigeeRegistry/V1/GetApiRequest.php | 86 - .../V1/GetApiSpecContentsRequest.php | 86 - .../ApigeeRegistry/V1/GetApiSpecRequest.php | 86 - .../V1/GetApiVersionRequest.php | 86 - .../V1/GetArtifactContentsRequest.php | 86 - .../ApigeeRegistry/V1/GetArtifactRequest.php | 86 - .../ApigeeRegistry/V1/GetInstanceRequest.php | 86 - .../Cloud/ApigeeRegistry/V1/Instance.php | 272 -- .../ApigeeRegistry/V1/Instance/Config.php | 116 - .../ApigeeRegistry/V1/Instance/State.php | 92 - .../ApigeeRegistry/V1/Instance_Config.php | 16 - .../ApigeeRegistry/V1/Instance_State.php | 16 - .../V1/ListApiDeploymentRevisionsRequest.php | 139 - .../V1/ListApiDeploymentRevisionsResponse.php | 105 - .../V1/ListApiDeploymentsRequest.php | 216 -- .../V1/ListApiDeploymentsResponse.php | 105 - .../V1/ListApiSpecRevisionsRequest.php | 139 - .../V1/ListApiSpecRevisionsResponse.php | 105 - .../ApigeeRegistry/V1/ListApiSpecsRequest.php | 216 -- .../V1/ListApiSpecsResponse.php | 105 - .../V1/ListApiVersionsRequest.php | 216 -- .../V1/ListApiVersionsResponse.php | 105 - .../ApigeeRegistry/V1/ListApisRequest.php | 216 -- .../ApigeeRegistry/V1/ListApisResponse.php | 105 - .../V1/ListArtifactsRequest.php | 216 -- .../V1/ListArtifactsResponse.php | 105 - .../ApigeeRegistry/V1/OperationMetadata.php | 303 -- .../V1/ProvisioningGrpcClient.php | 81 - .../ApigeeRegistry/V1/RegistryGrpcClient.php | 575 ---- .../V1/ReplaceArtifactRequest.php | 101 - .../V1/RollbackApiDeploymentRequest.php | 109 - .../V1/RollbackApiSpecRequest.php | 109 - .../V1/TagApiDeploymentRevisionRequest.php | 105 - .../V1/TagApiSpecRevisionRequest.php | 105 - .../V1/UpdateApiDeploymentRequest.php | 200 -- .../ApigeeRegistry/V1/UpdateApiRequest.php | 200 -- .../V1/UpdateApiSpecRequest.php | 200 -- .../V1/UpdateApiVersionRequest.php | 200 -- .../V1/ProvisioningClient/create_instance.php | 101 - .../V1/ProvisioningClient/delete_instance.php | 81 - .../V1/ProvisioningClient/get_iam_policy.php | 72 - .../V1/ProvisioningClient/get_instance.php | 72 - .../V1/ProvisioningClient/get_location.php | 57 - .../V1/ProvisioningClient/list_locations.php | 62 - .../V1/ProvisioningClient/set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../samples/V1/RegistryClient/create_api.php | 83 - .../RegistryClient/create_api_deployment.php | 83 - .../V1/RegistryClient/create_api_spec.php | 83 - .../V1/RegistryClient/create_api_version.php | 83 - .../V1/RegistryClient/create_artifact.php | 83 - .../samples/V1/RegistryClient/delete_api.php | 71 - .../RegistryClient/delete_api_deployment.php | 76 - .../delete_api_deployment_revision.php | 80 - .../V1/RegistryClient/delete_api_spec.php | 77 - .../delete_api_spec_revision.php | 81 - .../V1/RegistryClient/delete_api_version.php | 71 - .../V1/RegistryClient/delete_artifact.php | 70 - .../v1/samples/V1/RegistryClient/get_api.php | 72 - .../V1/RegistryClient/get_api_deployment.php | 77 - .../V1/RegistryClient/get_api_spec.php | 78 - .../RegistryClient/get_api_spec_contents.php | 81 - .../V1/RegistryClient/get_api_version.php | 72 - .../V1/RegistryClient/get_artifact.php | 72 - .../RegistryClient/get_artifact_contents.php | 75 - .../V1/RegistryClient/get_iam_policy.php | 72 - .../V1/RegistryClient/get_location.php | 57 - .../list_api_deployment_revisions.php | 82 - .../RegistryClient/list_api_deployments.php | 77 - .../list_api_spec_revisions.php | 83 - .../V1/RegistryClient/list_api_specs.php | 77 - .../V1/RegistryClient/list_api_versions.php | 77 - .../samples/V1/RegistryClient/list_apis.php | 77 - .../V1/RegistryClient/list_artifacts.php | 77 - .../V1/RegistryClient/list_locations.php | 62 - .../V1/RegistryClient/replace_artifact.php | 59 - .../rollback_api_deployment.php | 83 - .../V1/RegistryClient/rollback_api_spec.php | 84 - .../V1/RegistryClient/set_iam_policy.php | 77 - .../tag_api_deployment_revision.php | 81 - .../RegistryClient/tag_api_spec_revision.php | 81 - .../RegistryClient/test_iam_permissions.php | 84 - .../samples/V1/RegistryClient/update_api.php | 59 - .../RegistryClient/update_api_deployment.php | 59 - .../V1/RegistryClient/update_api_spec.php | 59 - .../V1/RegistryClient/update_api_version.php | 59 - .../src/V1/Gapic/ProvisioningGapicClient.php | 803 ----- .../v1/src/V1/Gapic/RegistryGapicClient.php | 2750 ---------------- .../v1/src/V1/ProvisioningClient.php | 34 - .../v1/src/V1/RegistryClient.php | 34 - .../v1/src/V1/gapic_metadata.json | 267 -- .../resources/provisioning_client_config.json | 62 - .../provisioning_descriptor_config.php | 135 - .../provisioning_rest_client_config.php | 286 -- .../V1/resources/registry_client_config.json | 247 -- .../resources/registry_descriptor_config.php | 575 ---- .../resources/registry_rest_client_config.php | 796 ----- .../tests/Unit/V1/ProvisioningClientTest.php | 697 ---- .../v1/tests/Unit/V1/RegistryClientTest.php | 2853 ----------------- .../V2/Baremetalsolution.php | 77 - .../Cloud/Baremetalsolution/V2/Instance.php | Bin 3954 -> 0 bytes .../Google/Cloud/Baremetalsolution/V2/Lun.php | Bin 2083 -> 0 bytes .../Cloud/Baremetalsolution/V2/Network.php | Bin 3517 -> 0 bytes .../Cloud/Baremetalsolution/V2/NfsShare.php | Bin 2573 -> 0 bytes .../Cloud/Baremetalsolution/V2/Volume.php | Bin 2966 -> 0 bytes .../V2/BareMetalSolutionGrpcClient.php | 344 -- .../BareMetalSolution/V2/DetachLunRequest.php | 118 - .../V2/GetInstanceRequest.php | 81 - .../BareMetalSolution/V2/GetLunRequest.php | 81 - .../V2/GetNetworkRequest.php | 81 - .../V2/GetNfsShareRequest.php | 81 - .../BareMetalSolution/V2/GetVolumeRequest.php | 81 - .../Cloud/BareMetalSolution/V2/Instance.php | 643 ---- .../BareMetalSolution/V2/Instance/State.php | 71 - .../BareMetalSolution/V2/Instance_State.php | 16 - .../V2/ListInstancesRequest.php | 187 -- .../V2/ListInstancesResponse.php | 135 - .../BareMetalSolution/V2/ListLunsRequest.php | 153 - .../BareMetalSolution/V2/ListLunsResponse.php | 135 - .../V2/ListNetworkUsageRequest.php | 81 - .../V2/ListNetworkUsageResponse.php | 67 - .../V2/ListNetworksRequest.php | 187 -- .../V2/ListNetworksResponse.php | 135 - .../V2/ListNfsSharesRequest.php | 187 -- .../V2/ListNfsSharesResponse.php | 135 - .../V2/ListVolumesRequest.php | 187 -- .../V2/ListVolumesResponse.php | 135 - .../BareMetalSolution/V2/LogicalInterface.php | 146 - .../LogicalNetworkInterface.php | 210 -- ...gicalInterface_LogicalNetworkInterface.php | 16 - .../Google/Cloud/BareMetalSolution/V2/Lun.php | 377 --- .../V2/Lun/MultiprotocolType.php | 57 - .../Cloud/BareMetalSolution/V2/Lun/State.php | 78 - .../BareMetalSolution/V2/Lun/StorageType.php | 64 - .../V2/Lun_MultiprotocolType.php | 16 - .../Cloud/BareMetalSolution/V2/Lun_State.php | 16 - .../BareMetalSolution/V2/Lun_StorageType.php | 16 - .../Cloud/BareMetalSolution/V2/Network.php | 475 --- .../BareMetalSolution/V2/Network/State.php | 64 - .../BareMetalSolution/V2/Network/Type.php | 68 - .../V2/NetworkAddressReservation.php | 151 - .../BareMetalSolution/V2/NetworkUsage.php | 111 - .../BareMetalSolution/V2/Network_State.php | 16 - .../BareMetalSolution/V2/Network_Type.php | 16 - .../Cloud/BareMetalSolution/V2/NfsShare.php | 237 -- .../V2/NfsShare/AllowedClient.php | 282 -- .../V2/NfsShare/MountPermissions.php | 64 - .../BareMetalSolution/V2/NfsShare/State.php | 57 - .../V2/NfsShare_AllowedClient.php | 16 - .../V2/NfsShare_MountPermissions.php | 16 - .../BareMetalSolution/V2/NfsShare_State.php | 16 - .../V2/OperationMetadata.php | 303 -- .../V2/ResetInstanceRequest.php | 81 - .../V2/ResetInstanceResponse.php | 33 - .../V2/ResizeVolumeRequest.php | 117 - .../V2/ServerNetworkTemplate.php | 147 - .../LogicalInterface.php | 154 - .../LogicalInterface/InterfaceType.php | 64 - ...ServerNetworkTemplate_LogicalInterface.php | 16 - ...emplate_LogicalInterface_InterfaceType.php | 16 - .../V2/StartInstanceRequest.php | 81 - .../V2/StartInstanceResponse.php | 33 - .../V2/StopInstanceRequest.php | 81 - .../V2/StopInstanceResponse.php | 33 - .../V2/UpdateInstanceRequest.php | 167 - .../V2/UpdateNetworkRequest.php | 157 - .../V2/UpdateNfsShareRequest.php | 157 - .../V2/UpdateVolumeRequest.php | 177 - .../Google/Cloud/BareMetalSolution/V2/VRF.php | 179 -- .../BareMetalSolution/V2/VRF/QosPolicy.php | 70 - .../Cloud/BareMetalSolution/V2/VRF/State.php | 64 - .../V2/VRF/VlanAttachment.php | 138 - .../BareMetalSolution/V2/VRF_QosPolicy.php | 16 - .../Cloud/BareMetalSolution/V2/VRF_State.php | 16 - .../V2/VRF_VlanAttachment.php | 16 - .../Cloud/BareMetalSolution/V2/Volume.php | 555 ---- .../V2/Volume/SnapshotAutoDeleteBehavior.php | 73 - .../V2/Volume/SnapshotReservationDetail.php | 204 -- .../BareMetalSolution/V2/Volume/State.php | 71 - .../V2/Volume/StorageType.php | 64 - .../V2/Volume_SnapshotAutoDeleteBehavior.php | 16 - .../V2/Volume_SnapshotReservationDetail.php | 16 - .../BareMetalSolution/V2/Volume_State.php | 16 - .../V2/Volume_StorageType.php | 16 - .../V2/BareMetalSolutionClient/detach_lun.php | 87 - .../BareMetalSolutionClient/get_instance.php | 71 - .../V2/BareMetalSolutionClient/get_lun.php | 71 - .../BareMetalSolutionClient/get_network.php | 71 - .../BareMetalSolutionClient/get_nfs_share.php | 71 - .../V2/BareMetalSolutionClient/get_volume.php | 71 - .../list_instances.php | 76 - .../V2/BareMetalSolutionClient/list_luns.php | 76 - .../list_network_usage.php | 72 - .../BareMetalSolutionClient/list_networks.php | 76 - .../list_nfs_shares.php | 76 - .../BareMetalSolutionClient/list_volumes.php | 76 - .../reset_instance.php | 84 - .../BareMetalSolutionClient/resize_volume.php | 83 - .../start_instance.php | 83 - .../BareMetalSolutionClient/stop_instance.php | 83 - .../update_instance.php | 71 - .../update_network.php | 71 - .../update_nfs_share.php | 71 - .../BareMetalSolutionClient/update_volume.php | 71 - .../v2/src/V2/BareMetalSolutionClient.php | 34 - .../V2/Gapic/BareMetalSolutionGapicClient.php | 1768 ---------- .../v2/src/V2/gapic_metadata.json | 118 - .../bare_metal_solution_client_config.json | 132 - .../bare_metal_solution_descriptor_config.php | 364 --- ...bare_metal_solution_rest_client_config.php | 266 -- .../Unit/V2/BareMetalSolutionClientTest.php | 1975 ------------ .../Google/Cloud/Batch/V1/Batch.php | 91 - .../GPBMetadata/Google/Cloud/Batch/V1/Job.php | Bin 5386 -> 0 bytes .../Google/Cloud/Batch/V1/Task.php | Bin 3688 -> 0 bytes .../Google/Cloud/Batch/V1/Volume.php | Bin 1026 -> 0 bytes .../Cloud/Batch/V1/AllocationPolicy.php | 262 -- .../Batch/V1/AllocationPolicy/Accelerator.php | 147 - .../V1/AllocationPolicy/AttachedDisk.php | 153 - .../Cloud/Batch/V1/AllocationPolicy/Disk.php | 298 -- .../V1/AllocationPolicy/InstancePolicy.php | 271 -- .../InstancePolicyOrTemplate.php | 163 - .../V1/AllocationPolicy/LocationPolicy.php | 112 - .../V1/AllocationPolicy/NetworkInterface.php | 202 -- .../V1/AllocationPolicy/NetworkPolicy.php | 70 - .../V1/AllocationPolicy/ProvisioningModel.php | 75 - .../Batch/V1/AllocationPolicy_Accelerator.php | 16 - .../V1/AllocationPolicy_AttachedDisk.php | 16 - .../Cloud/Batch/V1/AllocationPolicy_Disk.php | 16 - .../V1/AllocationPolicy_InstancePolicy.php | 16 - ...ocationPolicy_InstancePolicyOrTemplate.php | 16 - .../V1/AllocationPolicy_LocationPolicy.php | 16 - .../V1/AllocationPolicy_NetworkInterface.php | 16 - .../V1/AllocationPolicy_NetworkPolicy.php | 16 - .../V1/AllocationPolicy_ProvisioningModel.php | 16 - .../Cloud/Batch/V1/BatchServiceGrpcClient.php | 127 - .../Google/Cloud/Batch/V1/ComputeResource.php | 135 - .../Cloud/Batch/V1/CreateJobRequest.php | 278 -- .../Cloud/Batch/V1/DeleteJobRequest.php | 188 -- .../src/Google/Cloud/Batch/V1/Environment.php | 158 - .../Cloud/Batch/V1/Environment/KMSEnvMap.php | 102 - .../Cloud/Batch/V1/Environment_KMSEnvMap.php | 16 - .../proto/src/Google/Cloud/Batch/V1/GCS.php | 71 - .../Google/Cloud/Batch/V1/GetJobRequest.php | 81 - .../Google/Cloud/Batch/V1/GetTaskRequest.php | 81 - .../proto/src/Google/Cloud/Batch/V1/Job.php | 513 --- .../Google/Cloud/Batch/V1/JobNotification.php | 131 - .../Batch/V1/JobNotification/Message.php | 140 - .../Cloud/Batch/V1/JobNotification/Type.php | 64 - .../Batch/V1/JobNotification_Message.php | 16 - .../Cloud/Batch/V1/JobNotification_Type.php | 16 - .../src/Google/Cloud/Batch/V1/JobStatus.php | 183 -- .../Batch/V1/JobStatus/InstanceStatus.php | 182 -- .../Google/Cloud/Batch/V1/JobStatus/State.php | 94 - .../Batch/V1/JobStatus/TaskGroupStatus.php | 108 - .../Batch/V1/JobStatus_InstanceStatus.php | 16 - .../Google/Cloud/Batch/V1/JobStatus_State.php | 16 - .../Batch/V1/JobStatus_TaskGroupStatus.php | 16 - .../Google/Cloud/Batch/V1/LifecyclePolicy.php | 128 - .../Cloud/Batch/V1/LifecyclePolicy/Action.php | 64 - .../V1/LifecyclePolicy/ActionCondition.php | 82 - .../Cloud/Batch/V1/LifecyclePolicy_Action.php | 16 - .../V1/LifecyclePolicy_ActionCondition.php | 16 - .../Google/Cloud/Batch/V1/ListJobsRequest.php | 182 -- .../Cloud/Batch/V1/ListJobsResponse.php | 135 - .../Cloud/Batch/V1/ListTasksRequest.php | 201 -- .../Cloud/Batch/V1/ListTasksResponse.php | 135 - .../src/Google/Cloud/Batch/V1/LogsPolicy.php | 110 - .../Cloud/Batch/V1/LogsPolicy/Destination.php | 64 - .../Cloud/Batch/V1/LogsPolicy_Destination.php | 16 - .../proto/src/Google/Cloud/Batch/V1/NFS.php | 101 - .../Cloud/Batch/V1/OperationMetadata.php | 307 -- .../src/Google/Cloud/Batch/V1/Runnable.php | 372 --- .../Cloud/Batch/V1/Runnable/Barrier.php | 74 - .../Cloud/Batch/V1/Runnable/Container.php | 352 -- .../Google/Cloud/Batch/V1/Runnable/Script.php | 147 - .../Cloud/Batch/V1/Runnable_Barrier.php | 16 - .../Cloud/Batch/V1/Runnable_Container.php | 16 - .../Google/Cloud/Batch/V1/Runnable_Script.php | 16 - .../Google/Cloud/Batch/V1/ServiceAccount.php | 117 - .../src/Google/Cloud/Batch/V1/StatusEvent.php | 223 -- .../proto/src/Google/Cloud/Batch/V1/Task.php | 123 - .../Google/Cloud/Batch/V1/TaskExecution.php | 72 - .../src/Google/Cloud/Batch/V1/TaskGroup.php | 388 --- .../src/Google/Cloud/Batch/V1/TaskSpec.php | 412 --- .../src/Google/Cloud/Batch/V1/TaskStatus.php | 101 - .../Cloud/Batch/V1/TaskStatus/State.php | 85 - .../Cloud/Batch/V1/TaskStatus_State.php | 16 - .../src/Google/Cloud/Batch/V1/Volume.php | 256 -- .../V1/BatchServiceClient/create_job.php | 81 - .../V1/BatchServiceClient/delete_job.php | 66 - .../samples/V1/BatchServiceClient/get_job.php | 71 - .../V1/BatchServiceClient/get_location.php | 57 - .../V1/BatchServiceClient/get_task.php | 77 - .../V1/BatchServiceClient/list_jobs.php | 62 - .../V1/BatchServiceClient/list_locations.php | 62 - .../V1/BatchServiceClient/list_tasks.php | 83 - .../Batch/v1/src/V1/BatchServiceClient.php | 34 - .../src/V1/Gapic/BatchServiceGapicClient.php | 910 ------ .../Batch/v1/src/V1/gapic_metadata.json | 58 - .../batch_service_client_config.json | 84 - .../batch_service_descriptor_config.php | 143 - .../batch_service_rest_client_config.php | 147 - .../tests/Unit/V1/BatchServiceClientTest.php | 628 ---- .../V1/AppConnectionsService.php | Bin 6753 -> 0 bytes .../AppConnections/V1/AppConnection.php | 470 --- .../V1/AppConnection/ApplicationEndpoint.php | 104 - .../V1/AppConnection/Gateway.php | 181 -- .../V1/AppConnection/Gateway/Type.php | 57 - .../AppConnections/V1/AppConnection/State.php | 86 - .../AppConnections/V1/AppConnection/Type.php | 59 - .../V1/AppConnectionOperationMetadata.php | 307 -- .../V1/AppConnection_ApplicationEndpoint.php | 16 - .../V1/AppConnection_Gateway.php | 16 - .../V1/AppConnection_Gateway_Type.php | 16 - .../AppConnections/V1/AppConnection_State.php | 16 - .../AppConnections/V1/AppConnection_Type.php | 16 - .../V1/AppConnectionsServiceGrpcClient.php | 140 - .../V1/CreateAppConnectionRequest.php | 295 -- .../V1/DeleteAppConnectionRequest.php | 198 -- .../V1/GetAppConnectionRequest.php | 86 - .../V1/ListAppConnectionsRequest.php | 258 -- .../V1/ListAppConnectionsResponse.php | 139 - .../V1/ResolveAppConnectionsRequest.php | 220 -- .../V1/ResolveAppConnectionsResponse.php | 139 - .../AppConnectionDetails.php | 118 - ...nnectionsResponse_AppConnectionDetails.php | 16 - .../V1/UpdateAppConnectionRequest.php | 317 -- .../create_app_connection.php | 114 - .../delete_app_connection.php | 85 - .../get_app_connection.php | 76 - .../get_iam_policy.php | 72 - .../get_location.php | 57 - .../list_app_connections.php | 77 - .../list_locations.php | 62 - .../resolve_app_connections.php | 91 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../update_app_connection.php | 110 - .../v1/src/V1/AppConnectionsServiceClient.php | 34 - .../AppConnectionsServiceGapicClient.php | 1204 ------- .../v1/src/V1/gapic_metadata.json | 73 - ...app_connections_service_client_config.json | 77 - ..._connections_service_descriptor_config.php | 197 -- ...connections_service_rest_client_config.php | 251 -- .../V1/AppConnectionsServiceClientTest.php | 1001 ------ .../V1/AppConnectorInstanceConfig.php | Bin 1743 -> 0 bytes .../Appconnectors/V1/AppConnectorsService.php | Bin 6117 -> 0 bytes .../Appconnectors/V1/ResourceInfo.php | Bin 1587 -> 0 bytes .../AppConnectors/V1/AppConnector.php | 395 --- .../V1/AppConnector/PrincipalInfo.php | 78 - .../PrincipalInfo/ServiceAccount.php | 70 - .../AppConnectors/V1/AppConnector/State.php | 86 - .../V1/AppConnectorInstanceConfig.php | 215 -- .../V1/AppConnectorOperationMetadata.php | 307 -- .../V1/AppConnector_PrincipalInfo.php | 16 - ...Connector_PrincipalInfo_ServiceAccount.php | 16 - .../AppConnectors/V1/AppConnector_State.php | 16 - .../V1/AppConnectorsServiceGrpcClient.php | 138 - .../V1/CreateAppConnectorRequest.php | 296 -- .../V1/DeleteAppConnectorRequest.php | 198 -- .../V1/GetAppConnectorRequest.php | 86 - .../AppConnectors/V1/HealthStatus.php | 75 - .../AppConnectors/V1/ImageConfig.php | 109 - .../V1/ListAppConnectorsRequest.php | 258 -- .../V1/ListAppConnectorsResponse.php | 139 - .../AppConnectors/V1/NotificationConfig.php | 75 - .../CloudPubSubNotificationConfig.php | 70 - ...onConfig_CloudPubSubNotificationConfig.php | 16 - .../AppConnectors/V1/ReportStatusRequest.php | 244 -- .../AppConnectors/V1/ResourceInfo.php | 240 -- .../V1/UpdateAppConnectorRequest.php | 273 -- .../create_app_connector.php | 93 - .../delete_app_connector.php | 85 - .../get_app_connector.php | 76 - .../get_iam_policy.php | 72 - .../get_location.php | 57 - .../list_app_connectors.php | 77 - .../list_locations.php | 62 - .../report_status.php | 94 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../update_app_connector.php | 91 - .../v1/src/V1/AppConnectorsServiceClient.php | 34 - .../Gapic/AppConnectorsServiceGapicClient.php | 1150 ------- .../v1/src/V1/gapic_metadata.json | 73 - .../app_connectors_service_client_config.json | 77 - ...p_connectors_service_descriptor_config.php | 194 -- ..._connectors_service_rest_client_config.php | 252 -- .../V1/AppConnectorsServiceClientTest.php | 1034 ------ .../Appgateways/V1/AppGatewaysService.php | Bin 4655 -> 0 bytes .../BeyondCorp/AppGateways/V1/AppGateway.php | 442 --- .../V1/AppGateway/AllocatedConnection.php | 104 - .../AppGateways/V1/AppGateway/HostType.php | 58 - .../AppGateways/V1/AppGateway/State.php | 86 - .../AppGateways/V1/AppGateway/Type.php | 58 - .../V1/AppGatewayOperationMetadata.php | 307 -- .../V1/AppGateway_AllocatedConnection.php | 16 - .../AppGateways/V1/AppGateway_HostType.php | 16 - .../AppGateways/V1/AppGateway_State.php | 16 - .../AppGateways/V1/AppGateway_Type.php | 16 - .../V1/AppGatewaysServiceGrpcClient.php | 108 - .../V1/CreateAppGatewayRequest.php | 295 -- .../V1/DeleteAppGatewayRequest.php | 198 -- .../AppGateways/V1/GetAppGatewayRequest.php | 86 - .../AppGateways/V1/ListAppGatewaysRequest.php | 258 -- .../V1/ListAppGatewaysResponse.php | 139 - .../create_app_gateway.php | 102 - .../delete_app_gateway.php | 85 - .../get_app_gateway.php | 76 - .../get_iam_policy.php | 72 - .../AppGatewaysServiceClient/get_location.php | 57 - .../list_app_gateways.php | 77 - .../list_locations.php | 62 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../v1/src/V1/AppGatewaysServiceClient.php | 34 - .../Gapic/AppGatewaysServiceGapicClient.php | 956 ------ .../v1/src/V1/gapic_metadata.json | 63 - .../app_gateways_service_client_config.json | 67 - ...app_gateways_service_descriptor_config.php | 155 - ...pp_gateways_service_rest_client_config.php | 224 -- .../Unit/V1/AppGatewaysServiceClientTest.php | 775 ----- .../V1/ClientConnectorServicesService.php | Bin 6575 -> 0 bytes .../V1/ClientConnectorService.php | 327 -- .../V1/ClientConnectorService/Egress.php | 78 - .../Egress/PeeredVpc.php | 70 - .../V1/ClientConnectorService/Ingress.php | 79 - .../ClientConnectorService/Ingress/Config.php | 108 - .../Ingress/Config/DestinationRoute.php | 114 - .../Ingress/Config/TransportProtocol.php | 57 - .../V1/ClientConnectorService/State.php | 94 - ...lientConnectorServiceOperationMetadata.php | 307 -- .../V1/ClientConnectorService_Egress.php | 16 - ...lientConnectorService_Egress_PeeredVpc.php | 16 - .../V1/ClientConnectorService_Ingress.php | 16 - .../ClientConnectorService_Ingress_Config.php | 16 - ...ervice_Ingress_Config_DestinationRoute.php | 16 - ...rvice_Ingress_Config_TransportProtocol.php | 16 - .../V1/ClientConnectorService_State.php | 16 - ...ientConnectorServicesServiceGrpcClient.php | 120 - .../CreateClientConnectorServiceRequest.php | 301 -- .../DeleteClientConnectorServiceRequest.php | 193 -- .../V1/GetClientConnectorServiceRequest.php | 81 - .../V1/ListClientConnectorServicesRequest.php | 221 -- .../ListClientConnectorServicesResponse.php | 135 - .../UpdateClientConnectorServiceRequest.php | 308 -- .../create_client_connector_service.php | 96 - .../delete_client_connector_service.php | 84 - .../get_client_connector_service.php | 75 - .../get_iam_policy.php | 72 - .../get_location.php | 57 - .../list_client_connector_services.php | 76 - .../list_locations.php | 62 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../update_client_connector_service.php | 93 - .../ClientConnectorServicesServiceClient.php | 34 - ...entConnectorServicesServiceGapicClient.php | 1054 ------ .../v1/src/V1/gapic_metadata.json | 68 - ...nector_services_service_client_config.json | 72 - ...tor_services_service_descriptor_config.php | 175 - ...or_services_service_rest_client_config.php | 240 -- ...ientConnectorServicesServiceClientTest.php | 905 ------ .../V1/ClientGatewaysService.php | Bin 4281 -> 0 bytes .../ClientGateways/V1/ClientGateway.php | 265 -- .../ClientGateways/V1/ClientGateway/State.php | 93 - .../V1/ClientGatewayOperationMetadata.php | 307 -- .../ClientGateways/V1/ClientGateway_State.php | 16 - .../V1/ClientGatewaysServiceGrpcClient.php | 105 - .../V1/CreateClientGatewayRequest.php | 290 -- .../V1/DeleteClientGatewayRequest.php | 193 -- .../V1/GetClientGatewayRequest.php | 81 - .../V1/ListClientGatewaysRequest.php | 221 -- .../V1/ListClientGatewaysResponse.php | 135 - .../create_client_gateway.php | 88 - .../delete_client_gateway.php | 84 - .../get_client_gateway.php | 75 - .../get_iam_policy.php | 72 - .../get_location.php | 57 - .../list_client_gateways.php | 76 - .../list_locations.php | 62 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../v1/src/V1/ClientGatewaysServiceClient.php | 34 - .../ClientGatewaysServiceGapicClient.php | 946 ------ .../v1/src/V1/gapic_metadata.json | 63 - ...client_gateways_service_client_config.json | 67 - ...ent_gateways_service_descriptor_config.php | 155 - ...nt_gateways_service_rest_client_config.php | 224 -- .../V1/ClientGatewaysServiceClientTest.php | 761 ----- .../Bigquery/Analyticshub/V1/Analyticshub.php | Bin 9700 -> 0 bytes .../V1/AnalyticsHubServiceGrpcClient.php | 271 -- .../V1/CreateDataExchangeRequest.php | 182 -- .../AnalyticsHub/V1/CreateListingRequest.php | 182 -- .../BigQuery/AnalyticsHub/V1/DataExchange.php | 329 -- .../BigQuery/AnalyticsHub/V1/DataProvider.php | 105 - .../V1/DeleteDataExchangeRequest.php | 86 - .../AnalyticsHub/V1/DeleteListingRequest.php | 86 - .../AnalyticsHub/V1/DestinationDataset.php | 311 -- .../V1/DestinationDatasetReference.php | 109 - .../V1/GetDataExchangeRequest.php | 86 - .../AnalyticsHub/V1/GetListingRequest.php | 86 - .../V1/ListDataExchangesRequest.php | 162 - .../V1/ListDataExchangesResponse.php | 101 - .../AnalyticsHub/V1/ListListingsRequest.php | 162 - .../AnalyticsHub/V1/ListListingsResponse.php | 101 - .../V1/ListOrgDataExchangesRequest.php | 162 - .../V1/ListOrgDataExchangesResponse.php | 102 - .../BigQuery/AnalyticsHub/V1/Listing.php | 540 ---- .../V1/Listing/BigQueryDatasetSource.php | 80 - .../AnalyticsHub/V1/Listing/Category.php | 143 - .../AnalyticsHub/V1/Listing/State.php | 58 - .../V1/Listing_BigQueryDatasetSource.php | 16 - .../AnalyticsHub/V1/Listing_Category.php | 16 - .../AnalyticsHub/V1/Listing_State.php | 16 - .../BigQuery/AnalyticsHub/V1/Publisher.php | 105 - .../V1/SubscribeListingRequest.php | 128 - .../V1/SubscribeListingResponse.php | 33 - .../V1/UpdateDataExchangeRequest.php | 146 - .../AnalyticsHub/V1/UpdateListingRequest.php | 146 - .../create_data_exchange.php | 91 - .../create_listing.php | 98 - .../delete_data_exchange.php | 74 - .../delete_listing.php | 75 - .../get_data_exchange.php | 76 - .../get_iam_policy.php | 71 - .../AnalyticsHubServiceClient/get_listing.php | 77 - .../list_data_exchanges.php | 77 - .../list_listings.php | 81 - .../list_org_data_exchanges.php | 77 - .../set_iam_policy.php | 73 - .../subscribe_listing.php | 82 - .../test_iam_permissions.php | 78 - .../update_data_exchange.php | 79 - .../update_listing.php | 82 - .../v1/src/V1/AnalyticsHubServiceClient.php | 34 - .../Gapic/AnalyticsHubServiceGapicClient.php | 1122 ------- .../v1/src/V1/gapic_metadata.json | 93 - .../analytics_hub_service_client_config.json | 110 - ...nalytics_hub_service_descriptor_config.php | 220 -- ...alytics_hub_service_rest_client_config.php | 216 -- .../Unit/V1/AnalyticsHubServiceClientTest.php | 1117 ------- .../Dataexchange/V1Beta1/Dataexchange.php | Bin 10020 -> 0 bytes .../V1beta1/AnalyticsHubServiceGrpcClient.php | 271 -- .../V1beta1/CreateDataExchangeRequest.php | 182 -- .../V1beta1/CreateListingRequest.php | 182 -- .../DataExchange/V1beta1/DataExchange.php | 329 -- .../DataExchange/V1beta1/DataProvider.php | 105 - .../V1beta1/DeleteDataExchangeRequest.php | 86 - .../V1beta1/DeleteListingRequest.php | 86 - .../V1beta1/DestinationDataset.php | 311 -- .../V1beta1/DestinationDatasetReference.php | 109 - .../V1beta1/GetDataExchangeRequest.php | 86 - .../V1beta1/GetListingRequest.php | 86 - .../V1beta1/ListDataExchangesRequest.php | 162 - .../V1beta1/ListDataExchangesResponse.php | 101 - .../V1beta1/ListListingsRequest.php | 162 - .../V1beta1/ListListingsResponse.php | 101 - .../V1beta1/ListOrgDataExchangesRequest.php | 162 - .../V1beta1/ListOrgDataExchangesResponse.php | 102 - .../BigQuery/DataExchange/V1beta1/Listing.php | 540 ---- .../V1beta1/Listing/BigQueryDatasetSource.php | 80 - .../DataExchange/V1beta1/Listing/Category.php | 143 - .../DataExchange/V1beta1/Listing/State.php | 58 - .../V1beta1/Listing_BigQueryDatasetSource.php | 16 - .../DataExchange/V1beta1/Listing_Category.php | 16 - .../DataExchange/V1beta1/Listing_State.php | 16 - .../DataExchange/V1beta1/Publisher.php | 105 - .../V1beta1/SubscribeListingRequest.php | 128 - .../V1beta1/SubscribeListingResponse.php | 33 - .../V1beta1/UpdateDataExchangeRequest.php | 146 - .../V1beta1/UpdateListingRequest.php | 146 - .../create_data_exchange.php | 91 - .../create_listing.php | 98 - .../delete_data_exchange.php | 74 - .../delete_listing.php | 75 - .../get_data_exchange.php | 76 - .../get_iam_policy.php | 71 - .../AnalyticsHubServiceClient/get_listing.php | 77 - .../get_location.php | 57 - .../list_data_exchanges.php | 77 - .../list_listings.php | 81 - .../list_locations.php | 62 - .../list_org_data_exchanges.php | 77 - .../set_iam_policy.php | 73 - .../subscribe_listing.php | 82 - .../test_iam_permissions.php | 78 - .../update_data_exchange.php | 79 - .../update_listing.php | 82 - .../src/V1beta1/AnalyticsHubServiceClient.php | 36 - .../Gapic/AnalyticsHubServiceGapicClient.php | 1296 -------- .../v1beta1/src/V1beta1/gapic_metadata.json | 103 - .../analytics_hub_service_client_config.json | 120 - ...nalytics_hub_service_descriptor_config.php | 254 -- ...alytics_hub_service_rest_client_config.php | 240 -- .../V1beta1/AnalyticsHubServiceClientTest.php | 1239 ------- .../Bigquery/Datapolicies/V1/Datapolicy.php | Bin 5222 -> 0 bytes .../V1/CreateDataPolicyRequest.php | 137 - .../DataPolicies/V1/DataMaskingPolicy.php | 75 - .../PredefinedExpression.php | 89 - ...DataMaskingPolicy_PredefinedExpression.php | 16 - .../BigQuery/DataPolicies/V1/DataPolicy.php | 234 -- .../V1/DataPolicy/DataPolicyType.php | 65 - .../V1/DataPolicyServiceGrpcClient.php | 172 - .../V1/DataPolicy_DataPolicyType.php | 16 - .../V1/DeleteDataPolicyRequest.php | 86 - .../DataPolicies/V1/GetDataPolicyRequest.php | 86 - .../V1/ListDataPoliciesRequest.php | 224 -- .../V1/ListDataPoliciesResponse.php | 105 - .../V1/RenameDataPolicyRequest.php | 121 - .../V1/UpdateDataPolicyRequest.php | 168 - .../create_data_policy.php | 75 - .../delete_data_policy.php | 74 - .../get_data_policy.php | 76 - .../get_iam_policy.php | 71 - .../list_data_policies.php | 77 - .../rename_data_policy.php | 74 - .../set_iam_policy.php | 73 - .../test_iam_permissions.php | 78 - .../update_data_policy.php | 60 - .../v1/src/V1/DataPolicyServiceClient.php | 34 - .../V1/Gapic/DataPolicyServiceGapicClient.php | 739 ----- .../v1/src/V1/gapic_metadata.json | 63 - .../data_policy_service_client_config.json | 79 - .../data_policy_service_descriptor_config.php | 129 - ...data_policy_service_rest_client_config.php | 115 - .../Unit/V1/DataPolicyServiceClientTest.php | 644 ---- .../Datapolicies/V1Beta1/Datapolicy.php | Bin 5058 -> 0 bytes .../V1beta1/CreateDataPolicyRequest.php | 119 - .../V1beta1/DataMaskingPolicy.php | 75 - .../PredefinedExpression.php | 89 - ...DataMaskingPolicy_PredefinedExpression.php | 16 - .../DataPolicies/V1beta1/DataPolicy.php | 234 -- .../V1beta1/DataPolicy/DataPolicyType.php | 65 - .../V1beta1/DataPolicyServiceGrpcClient.php | 157 - .../V1beta1/DataPolicy_DataPolicyType.php | 16 - .../V1beta1/DeleteDataPolicyRequest.php | 71 - .../V1beta1/GetDataPolicyRequest.php | 71 - .../V1beta1/ListDataPoliciesRequest.php | 151 - .../V1beta1/ListDataPoliciesResponse.php | 105 - .../V1beta1/UpdateDataPolicyRequest.php | 145 - .../create_data_policy.php | 71 - .../delete_data_policy.php | 69 - .../get_data_policy.php | 71 - .../get_iam_policy.php | 66 - .../list_data_policies.php | 72 - .../set_iam_policy.php | 69 - .../test_iam_permissions.php | 74 - .../update_data_policy.php | 57 - .../src/V1beta1/DataPolicyServiceClient.php | 36 - .../Gapic/DataPolicyServiceGapicClient.php | 711 ---- .../v1beta1/src/V1beta1/gapic_metadata.json | 58 - .../data_policy_service_client_config.json | 74 - .../data_policy_service_descriptor_config.php | 18 - ...data_policy_service_rest_client_config.php | 102 - .../V1beta1/DataPolicyServiceClientTest.php | 576 ---- .../Migration/V2/MigrationEntities.php | Bin 3589 -> 0 bytes .../Migration/V2/MigrationErrorDetails.php | 40 - .../Migration/V2/MigrationMetrics.php | Bin 1890 -> 0 bytes .../Migration/V2/MigrationService.php | 81 - .../Migration/V2/TranslationConfig.php | Bin 3630 -> 0 bytes .../Migration/V2/AzureSynapseDialect.php | 33 - .../BigQuery/Migration/V2/BigQueryDialect.php | 33 - .../V2/CreateMigrationWorkflowRequest.php | 132 - .../V2/DeleteMigrationWorkflowRequest.php | 86 - .../Cloud/BigQuery/Migration/V2/Dialect.php | 504 --- .../BigQuery/Migration/V2/ErrorDetail.php | 122 - .../BigQuery/Migration/V2/ErrorLocation.php | 109 - .../V2/GetMigrationSubtaskRequest.php | 130 - .../V2/GetMigrationWorkflowRequest.php | 130 - .../BigQuery/Migration/V2/HiveQLDialect.php | 33 - .../V2/ListMigrationSubtasksRequest.php | 256 -- .../V2/ListMigrationSubtasksResponse.php | 105 - .../V2/ListMigrationWorkflowsRequest.php | 214 -- .../V2/ListMigrationWorkflowsResponse.php | 105 - .../V2/MigrationServiceGrpcClient.php | 143 - .../Migration/V2/MigrationSubtask.php | 449 --- .../Migration/V2/MigrationSubtask/State.php | 94 - .../Migration/V2/MigrationSubtask_State.php | 16 - .../BigQuery/Migration/V2/MigrationTask.php | 342 -- .../Migration/V2/MigrationTask/State.php | 93 - .../Migration/V2/MigrationTask_State.php | 16 - .../Migration/V2/MigrationWorkflow.php | 278 -- .../Migration/V2/MigrationWorkflow/State.php | 82 - .../Migration/V2/MigrationWorkflow_State.php | 16 - .../BigQuery/Migration/V2/MySQLDialect.php | 33 - .../BigQuery/Migration/V2/NameMappingKey.php | 216 -- .../Migration/V2/NameMappingKey/Type.php | 103 - .../Migration/V2/NameMappingKey_Type.php | 16 - .../Migration/V2/NameMappingValue.php | 182 -- .../BigQuery/Migration/V2/NetezzaDialect.php | 33 - .../Migration/V2/ObjectNameMapping.php | 122 - .../Migration/V2/ObjectNameMappingList.php | 68 - .../BigQuery/Migration/V2/OracleDialect.php | 33 - .../Cloud/BigQuery/Migration/V2/Point.php | 153 - .../Migration/V2/PostgresqlDialect.php | 33 - .../BigQuery/Migration/V2/PrestoDialect.php | 33 - .../BigQuery/Migration/V2/RedshiftDialect.php | 33 - .../Migration/V2/ResourceErrorDetail.php | 153 - .../Migration/V2/SQLServerDialect.php | 33 - .../Migration/V2/SnowflakeDialect.php | 33 - .../Cloud/BigQuery/Migration/V2/SourceEnv.php | 109 - .../BigQuery/Migration/V2/SparkSQLDialect.php | 33 - .../V2/StartMigrationWorkflowRequest.php | 86 - .../BigQuery/Migration/V2/TeradataDialect.php | 67 - .../Migration/V2/TeradataDialect/Mode.php | 64 - .../Migration/V2/TeradataDialect_Mode.php | 16 - .../BigQuery/Migration/V2/TimeInterval.php | 131 - .../BigQuery/Migration/V2/TimeSeries.php | 213 -- .../Migration/V2/TranslationConfigDetails.php | 326 -- .../BigQuery/Migration/V2/TypedValue.php | 213 -- .../BigQuery/Migration/V2/VerticaDialect.php | 33 - .../create_migration_workflow.php | 74 - .../delete_migration_workflow.php | 74 - .../get_migration_subtask.php | 77 - .../get_migration_workflow.php | 76 - .../list_migration_subtasks.php | 81 - .../list_migration_workflows.php | 77 - .../start_migration_workflow.php | 77 - .../V2/Gapic/MigrationServiceGapicClient.php | 691 ---- .../v2/src/V2/MigrationServiceClient.php | 34 - .../v2/src/V2/gapic_metadata.json | 53 - .../migration_service_client_config.json | 79 - .../migration_service_descriptor_config.php | 113 - .../migration_service_rest_client_config.php | 87 - .../Unit/V2/MigrationServiceClientTest.php | 509 --- .../Devtools/Cloudbuild/V1/Cloudbuild.php | Bin 23141 -> 0 bytes .../Google/Cloud/Build/V1/ApprovalConfig.php | 75 - .../Google/Cloud/Build/V1/ApprovalResult.php | 230 -- .../Build/V1/ApprovalResult/Decision.php | 65 - .../Build/V1/ApprovalResult_Decision.php | 16 - .../Cloud/Build/V1/ApproveBuildRequest.php | 115 - .../Google/Cloud/Build/V1/ArtifactResult.php | 110 - .../src/Google/Cloud/Build/V1/Artifacts.php | 314 -- .../Build/V1/Artifacts/ArtifactObjects.php | 165 - .../Build/V1/Artifacts/MavenArtifact.php | 251 -- .../Cloud/Build/V1/Artifacts/NpmPackage.php | 121 - .../Build/V1/Artifacts/PythonPackage.php | 126 - .../Build/V1/Artifacts_ArtifactObjects.php | 16 - .../Build/V1/Artifacts_MavenArtifact.php | 16 - .../Cloud/Build/V1/Artifacts_NpmPackage.php | 16 - .../Build/V1/Artifacts_PythonPackage.php | 16 - .../proto/src/Google/Cloud/Build/V1/Build.php | 1316 -------- .../Cloud/Build/V1/Build/FailureInfo.php | 104 - .../V1/Build/FailureInfo/FailureType.php | 93 - .../Google/Cloud/Build/V1/Build/Status.php | 114 - .../Google/Cloud/Build/V1/Build/Warning.php | 104 - .../Cloud/Build/V1/Build/Warning/Priority.php | 71 - .../Google/Cloud/Build/V1/BuildApproval.php | 156 - .../Cloud/Build/V1/BuildApproval/State.php | 78 - .../Cloud/Build/V1/BuildApproval_State.php | 16 - .../Cloud/Build/V1/BuildOperationMetadata.php | 77 - .../Google/Cloud/Build/V1/BuildOptions.php | 640 ---- .../DefaultLogsBucketBehavior.php | 59 - .../V1/BuildOptions/LogStreamingOption.php | 65 - .../Build/V1/BuildOptions/LoggingMode.php | 88 - .../Build/V1/BuildOptions/MachineType.php | 80 - .../Build/V1/BuildOptions/PoolOption.php | 85 - .../V1/BuildOptions/SubstitutionOption.php | 58 - .../Build/V1/BuildOptions/VerifyOption.php | 57 - ...BuildOptions_DefaultLogsBucketBehavior.php | 16 - .../V1/BuildOptions_LogStreamingOption.php | 16 - .../Build/V1/BuildOptions_LoggingMode.php | 16 - .../Build/V1/BuildOptions_MachineType.php | 16 - .../Build/V1/BuildOptions_PoolOption.php | 16 - .../V1/BuildOptions_SubstitutionOption.php | 16 - .../Build/V1/BuildOptions_VerifyOption.php | 16 - .../src/Google/Cloud/Build/V1/BuildStep.php | 841 ----- .../Google/Cloud/Build/V1/BuildTrigger.php | 881 ----- .../Cloud/Build/V1/Build_FailureInfo.php | 16 - .../V1/Build_FailureInfo_FailureType.php | 16 - .../Google/Cloud/Build/V1/Build_Status.php | 16 - .../Google/Cloud/Build/V1/Build_Warning.php | 16 - .../Cloud/Build/V1/Build_Warning_Priority.php | 16 - .../src/Google/Cloud/Build/V1/BuiltImage.php | 149 - .../Cloud/Build/V1/CancelBuildRequest.php | 139 - .../Cloud/Build/V1/CloudBuildGrpcClient.php | 364 --- .../Cloud/Build/V1/CreateBuildRequest.php | 149 - .../Build/V1/CreateBuildTriggerRequest.php | 149 - .../V1/CreateWorkerPoolOperationMetadata.php | 163 - .../Build/V1/CreateWorkerPoolRequest.php | 199 -- .../Build/V1/DeleteBuildTriggerRequest.php | 139 - .../V1/DeleteWorkerPoolOperationMetadata.php | 163 - .../Build/V1/DeleteWorkerPoolRequest.php | 189 -- .../src/Google/Cloud/Build/V1/FileHashes.php | 68 - .../Google/Cloud/Build/V1/GetBuildRequest.php | 139 - .../Cloud/Build/V1/GetBuildTriggerRequest.php | 139 - .../Cloud/Build/V1/GetWorkerPoolRequest.php | 71 - .../Cloud/Build/V1/GitHubEventsConfig.php | 229 -- .../src/Google/Cloud/Build/V1/GitSource.php | 179 -- .../proto/src/Google/Cloud/Build/V1/Hash.php | 101 - .../Google/Cloud/Build/V1/Hash/HashType.php | 71 - .../Google/Cloud/Build/V1/Hash_HashType.php | 16 - .../Google/Cloud/Build/V1/InlineSecret.php | 122 - .../Build/V1/ListBuildTriggersRequest.php | 173 - .../Build/V1/ListBuildTriggersResponse.php | 101 - .../Cloud/Build/V1/ListBuildsRequest.php | 227 -- .../Cloud/Build/V1/ListBuildsResponse.php | 105 - .../Cloud/Build/V1/ListWorkerPoolsRequest.php | 147 - .../Build/V1/ListWorkerPoolsResponse.php | 109 - .../Cloud/Build/V1/PrivatePoolV1Config.php | 121 - .../V1/PrivatePoolV1Config/NetworkConfig.php | 194 -- .../NetworkConfig/EgressOption.php | 66 - .../V1/PrivatePoolV1Config/WorkerConfig.php | 133 - .../V1/PrivatePoolV1Config_NetworkConfig.php | 16 - ...oolV1Config_NetworkConfig_EgressOption.php | 16 - .../V1/PrivatePoolV1Config_WorkerConfig.php | 16 - .../Google/Cloud/Build/V1/PubsubConfig.php | 182 -- .../Cloud/Build/V1/PubsubConfig/State.php | 79 - .../Cloud/Build/V1/PubsubConfig_State.php | 16 - .../Cloud/Build/V1/PullRequestFilter.php | 154 - .../V1/PullRequestFilter/CommentControl.php | 66 - .../V1/PullRequestFilter_CommentControl.php | 16 - .../src/Google/Cloud/Build/V1/PushFilter.php | 158 - .../Build/V1/ReceiveTriggerWebhookRequest.php | 218 -- .../V1/ReceiveTriggerWebhookResponse.php | 34 - .../src/Google/Cloud/Build/V1/RepoSource.php | 343 -- .../src/Google/Cloud/Build/V1/Results.php | 377 --- .../Cloud/Build/V1/RetryBuildRequest.php | 139 - .../Cloud/Build/V1/RunBuildTriggerRequest.php | 183 -- .../src/Google/Cloud/Build/V1/Secret.php | 121 - .../Cloud/Build/V1/SecretManagerSecret.php | 113 - .../src/Google/Cloud/Build/V1/Secrets.php | 105 - .../src/Google/Cloud/Build/V1/Source.php | 183 -- .../Cloud/Build/V1/SourceProvenance.php | 244 -- .../Google/Cloud/Build/V1/StorageSource.php | 155 - .../Cloud/Build/V1/StorageSourceManifest.php | 153 - .../src/Google/Cloud/Build/V1/TimeSpan.php | 121 - .../Build/V1/UpdateBuildTriggerRequest.php | 145 - .../V1/UpdateWorkerPoolOperationMetadata.php | 163 - .../Build/V1/UpdateWorkerPoolRequest.php | 167 - .../Cloud/Build/V1/UploadedMavenArtifact.php | 155 - .../Cloud/Build/V1/UploadedNpmPackage.php | 156 - .../Cloud/Build/V1/UploadedPythonPackage.php | 155 - .../src/Google/Cloud/Build/V1/Volume.php | 118 - .../Google/Cloud/Build/V1/WebhookConfig.php | 114 - .../Cloud/Build/V1/WebhookConfig/State.php | 65 - .../Cloud/Build/V1/WebhookConfig_State.php | 16 - .../src/Google/Cloud/Build/V1/WorkerPool.php | 465 --- .../Cloud/Build/V1/WorkerPool/State.php | 78 - .../Cloud/Build/V1/WorkerPool_State.php | 16 - .../V1/CloudBuildClient/approve_build.php | 83 - .../V1/CloudBuildClient/cancel_build.php | 67 - .../V1/CloudBuildClient/create_build.php | 84 - .../CloudBuildClient/create_build_trigger.php | 70 - .../CloudBuildClient/create_worker_pool.php | 88 - .../CloudBuildClient/delete_build_trigger.php | 67 - .../CloudBuildClient/delete_worker_pool.php | 77 - .../samples/V1/CloudBuildClient/get_build.php | 70 - .../V1/CloudBuildClient/get_build_trigger.php | 69 - .../V1/CloudBuildClient/get_worker_pool.php | 67 - .../CloudBuildClient/list_build_triggers.php | 72 - .../V1/CloudBuildClient/list_builds.php | 73 - .../V1/CloudBuildClient/list_worker_pools.php | 72 - .../receive_trigger_webhook.php | 54 - .../V1/CloudBuildClient/retry_build.php | 105 - .../V1/CloudBuildClient/run_build_trigger.php | 79 - .../CloudBuildClient/update_build_trigger.php | 72 - .../CloudBuildClient/update_worker_pool.php | 68 - .../Build/v1/src/V1/CloudBuildClient.php | 34 - .../v1/src/V1/Gapic/CloudBuildGapicClient.php | 2004 ------------ .../Build/v1/src/V1/gapic_metadata.json | 108 - .../resources/cloud_build_client_config.json | 116 - .../cloud_build_descriptor_config.php | 108 - .../cloud_build_rest_client_config.php | 445 --- .../v1/tests/Unit/V1/CloudBuildClientTest.php | 1768 ---------- .../Devtools/Cloudbuild/V2/Cloudbuild.php | 53 - .../Devtools/Cloudbuild/V2/Repositories.php | Bin 9721 -> 0 bytes .../V2/BatchCreateRepositoriesRequest.php | 132 - .../V2/BatchCreateRepositoriesResponse.php | 67 - .../src/Google/Cloud/Build/V2/Connection.php | 435 --- .../Build/V2/CreateConnectionRequest.php | 183 -- .../Build/V2/CreateRepositoryRequest.php | 188 -- .../Build/V2/DeleteConnectionRequest.php | 162 - .../Build/V2/DeleteRepositoryRequest.php | 162 - .../V2/FetchLinkableRepositoriesRequest.php | 139 - .../V2/FetchLinkableRepositoriesResponse.php | 101 - .../Cloud/Build/V2/FetchReadTokenRequest.php | 86 - .../Cloud/Build/V2/FetchReadTokenResponse.php | 111 - .../Build/V2/FetchReadWriteTokenRequest.php | 86 - .../Build/V2/FetchReadWriteTokenResponse.php | 111 - .../Cloud/Build/V2/GetConnectionRequest.php | 86 - .../Cloud/Build/V2/GetRepositoryRequest.php | 86 - .../Google/Cloud/Build/V2/GitHubConfig.php | 119 - .../Cloud/Build/V2/GitHubEnterpriseConfig.php | 407 --- .../Cloud/Build/V2/InstallationState.php | 145 - .../Build/V2/InstallationState/Stage.php | 79 - .../Build/V2/InstallationState_Stage.php | 16 - .../Cloud/Build/V2/ListConnectionsRequest.php | 154 - .../Build/V2/ListConnectionsResponse.php | 101 - .../Build/V2/ListRepositoriesRequest.php | 200 -- .../Build/V2/ListRepositoriesResponse.php | 101 - .../Google/Cloud/Build/V2/OAuthCredential.php | 106 - .../Cloud/Build/V2/OperationMetadata.php | 307 -- .../src/Google/Cloud/Build/V2/Repository.php | 269 -- .../Build/V2/RepositoryManagerGrpcClient.php | 231 -- .../V2/RunWorkflowCustomOperationMetadata.php | 307 -- .../Cloud/Build/V2/ServiceDirectoryConfig.php | 76 - .../Build/V2/UpdateConnectionRequest.php | 228 -- .../batch_create_repositories.php | 125 - .../create_connection.php | 92 - .../create_repository.php | 103 - .../delete_connection.php | 81 - .../delete_repository.php | 86 - .../fetch_linkable_repositories.php | 82 - .../fetch_read_token.php | 77 - .../fetch_read_write_token.php | 77 - .../get_connection.php | 72 - .../get_iam_policy.php | 72 - .../get_repository.php | 77 - .../list_connections.php | 77 - .../list_repositories.php | 81 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../update_connection.php | 71 - .../V2/Gapic/RepositoryManagerGapicClient.php | 1458 --------- .../v2/src/V2/RepositoryManagerClient.php | 34 - .../Build/v2/src/V2/gapic_metadata.json | 98 - .../repository_manager_client_config.json | 124 - .../repository_manager_descriptor_config.php | 277 -- .../repository_manager_rest_client_config.php | 227 -- .../Unit/V2/RepositoryManagerClientTest.php | 1467 --------- .../V1/CertificateIssuanceConfig.php | Bin 3473 -> 0 bytes .../V1/CertificateManager.php | Bin 16621 -> 0 bytes .../CertificateManager/V1/Certificate.php | 460 --- .../V1/Certificate/ManagedCertificate.php | 296 -- .../AuthorizationAttemptInfo.php | 185 -- .../FailureReason.php | 74 - .../AuthorizationAttemptInfo/State.php | 74 - .../ManagedCertificate/ProvisioningIssue.php | 112 - .../ProvisioningIssue/Reason.php | 68 - .../Certificate/ManagedCertificate/State.php | 77 - .../V1/Certificate/Scope.php | 63 - .../V1/Certificate/SelfManagedCertificate.php | 110 - .../V1/CertificateIssuanceConfig.php | 399 --- .../CertificateAuthorityConfig.php | 79 - .../CertificateAuthorityServiceConfig.php | 78 - .../KeyAlgorithm.php | 64 - ...uanceConfig_CertificateAuthorityConfig.php | 16 - ...nfig_CertificateAuthorityServiceConfig.php | 16 - ...CertificateIssuanceConfig_KeyAlgorithm.php | 16 - .../V1/CertificateManagerGrpcClient.php | 422 --- .../CertificateManager/V1/CertificateMap.php | 273 -- .../V1/CertificateMap/GclbTarget.php | 161 - .../V1/CertificateMap/GclbTarget/IpConfig.php | 104 - .../V1/CertificateMapEntry.php | 388 --- .../V1/CertificateMapEntry/Matcher.php | 59 - .../V1/CertificateMapEntry_Matcher.php | 16 - .../V1/CertificateMap_GclbTarget.php | 16 - .../V1/CertificateMap_GclbTarget_IpConfig.php | 16 - .../V1/Certificate_ManagedCertificate.php | 16 - ...edCertificate_AuthorizationAttemptInfo.php | 16 - ...AuthorizationAttemptInfo_FailureReason.php | 16 - ...ificate_AuthorizationAttemptInfo_State.php | 16 - ...e_ManagedCertificate_ProvisioningIssue.php | 16 - ...edCertificate_ProvisioningIssue_Reason.php | 16 - .../Certificate_ManagedCertificate_State.php | 16 - .../V1/Certificate_Scope.php | 16 - .../V1/Certificate_SelfManagedCertificate.php | 16 - ...CreateCertificateIssuanceConfigRequest.php | 168 - .../V1/CreateCertificateMapEntryRequest.php | 168 - .../V1/CreateCertificateMapRequest.php | 168 - .../V1/CreateCertificateRequest.php | 168 - .../V1/CreateDnsAuthorizationRequest.php | 168 - ...DeleteCertificateIssuanceConfigRequest.php | 86 - .../V1/DeleteCertificateMapEntryRequest.php | 86 - .../V1/DeleteCertificateMapRequest.php | 86 - .../V1/DeleteCertificateRequest.php | 86 - .../V1/DeleteDnsAuthorizationRequest.php | 86 - .../V1/DnsAuthorization.php | 326 -- .../V1/DnsAuthorization/DnsResourceRecord.php | 148 - .../V1/DnsAuthorization_DnsResourceRecord.php | 16 - .../GetCertificateIssuanceConfigRequest.php | 86 - .../V1/GetCertificateMapEntryRequest.php | 86 - .../V1/GetCertificateMapRequest.php | 86 - .../V1/GetCertificateRequest.php | 86 - .../V1/GetDnsAuthorizationRequest.php | 86 - .../ListCertificateIssuanceConfigsRequest.php | 242 -- ...ListCertificateIssuanceConfigsResponse.php | 143 - .../V1/ListCertificateMapEntriesRequest.php | 259 -- .../V1/ListCertificateMapEntriesResponse.php | 143 - .../V1/ListCertificateMapsRequest.php | 238 -- .../V1/ListCertificateMapsResponse.php | 143 - .../V1/ListCertificatesRequest.php | 238 -- .../V1/ListCertificatesResponse.php | 143 - .../V1/ListDnsAuthorizationsRequest.php | 238 -- .../V1/ListDnsAuthorizationsResponse.php | 143 - .../V1/OperationMetadata.php | 307 -- .../CertificateManager/V1/ServingState.php | 61 - .../V1/UpdateCertificateMapEntryRequest.php | 146 - .../V1/UpdateCertificateMapRequest.php | 146 - .../V1/UpdateCertificateRequest.php | 146 - .../V1/UpdateDnsAuthorizationRequest.php | 146 - .../create_certificate.php | 89 - .../create_certificate_issuance_config.php | 113 - .../create_certificate_map.php | 89 - .../create_certificate_map_entry.php | 95 - .../create_dns_authorization.php | 98 - .../delete_certificate.php | 85 - .../delete_certificate_issuance_config.php | 85 - .../delete_certificate_map.php | 87 - .../delete_certificate_map_entry.php | 86 - .../delete_dns_authorization.php | 85 - .../get_certificate.php | 76 - .../get_certificate_issuance_config.php | 76 - .../get_certificate_map.php | 76 - .../get_certificate_map_entry.php | 77 - .../get_dns_authorization.php | 76 - .../CertificateManagerClient/get_location.php | 57 - .../list_certificate_issuance_configs.php | 77 - .../list_certificate_map_entries.php | 82 - .../list_certificate_maps.php | 77 - .../list_certificates.php | 77 - .../list_dns_authorizations.php | 77 - .../list_locations.php | 62 - .../update_certificate.php | 74 - .../update_certificate_map.php | 74 - .../update_certificate_map_entry.php | 74 - .../update_dns_authorization.php | 90 - .../v1/src/V1/CertificateManagerClient.php | 34 - .../Gapic/CertificateManagerGapicClient.php | 2243 ------------- .../v1/src/V1/gapic_metadata.json | 148 - .../certificate_manager_client_config.json | 164 - .../certificate_manager_descriptor_config.php | 481 --- ...certificate_manager_rest_client_config.php | 384 --- .../Unit/V1/CertificateManagerClientTest.php | 2627 --------------- .../Confidentialcomputing/V1/Service.php | 71 - .../ConfidentialComputing/V1/Challenge.php | 231 -- .../V1/ConfidentialComputingGrpcClient.php | 65 - .../V1/CreateChallengeRequest.php | 137 - .../V1/GcpCredentials.php | 68 - .../V1/TpmAttestation.php | 228 -- .../V1/TpmAttestation/Quote.php | 173 - .../V1/TpmAttestation_Quote.php | 16 - .../V1/VerifyAttestationRequest.php | 172 - .../V1/VerifyAttestationResponse.php | 68 - .../create_challenge.php | 74 - .../get_location.php | 57 - .../list_locations.php | 62 - .../verify_attestation.php | 80 - .../v1/src/V1/ConfidentialComputingClient.php | 34 - .../ConfidentialComputingGapicClient.php | 498 --- .../v1/src/V1/gapic_metadata.json | 38 - .../confidential_computing_client_config.json | 64 - ...nfidential_computing_descriptor_config.php | 70 - ...fidential_computing_rest_client_config.php | 57 - .../V1/ConfidentialComputingClientTest.php | 317 -- .../Cloud/Datacatalog/Lineage/V1/Lineage.php | Bin 10731 -> 0 bytes .../V1/BatchSearchLinkProcessesRequest.php | 206 -- .../V1/BatchSearchLinkProcessesResponse.php | 106 - .../Lineage/V1/CreateLineageEventRequest.php | 170 - .../Lineage/V1/CreateProcessRequest.php | 175 - .../Lineage/V1/CreateRunRequest.php | 170 - .../Lineage/V1/DeleteLineageEventRequest.php | 120 - .../Lineage/V1/DeleteProcessRequest.php | 120 - .../Lineage/V1/DeleteRunRequest.php | 120 - .../Lineage/V1/EntityReference.php | 95 - .../DataCatalog/Lineage/V1/EventLink.php | 121 - .../Lineage/V1/GetLineageEventRequest.php | 82 - .../Lineage/V1/GetProcessRequest.php | 82 - .../DataCatalog/Lineage/V1/GetRunRequest.php | 82 - .../DataCatalog/Lineage/V1/LineageEvent.php | 226 -- .../Lineage/V1/LineageGrpcClient.php | 302 -- .../Cloud/DataCatalog/Lineage/V1/Link.php | 250 -- .../Lineage/V1/ListLineageEventsRequest.php | 178 - .../Lineage/V1/ListLineageEventsResponse.php | 106 - .../Lineage/V1/ListProcessesRequest.php | 179 -- .../Lineage/V1/ListProcessesResponse.php | 106 - .../Lineage/V1/ListRunsRequest.php | 174 - .../Lineage/V1/ListRunsResponse.php | 106 - .../Lineage/V1/OperationMetadata.php | 269 -- .../Lineage/V1/OperationMetadata/State.php | 78 - .../Lineage/V1/OperationMetadata/Type.php | 57 - .../Lineage/V1/OperationMetadata_State.php | 16 - .../Lineage/V1/OperationMetadata_Type.php | 16 - .../Cloud/DataCatalog/Lineage/V1/Origin.php | 129 - .../Lineage/V1/Origin/SourceType.php | 85 - .../Lineage/V1/Origin_SourceType.php | 16 - .../Cloud/DataCatalog/Lineage/V1/Process.php | 207 -- .../Lineage/V1/ProcessLinkInfo.php | 159 - .../DataCatalog/Lineage/V1/ProcessLinks.php | 121 - .../Cloud/DataCatalog/Lineage/V1/Run.php | 286 -- .../DataCatalog/Lineage/V1/Run/State.php | 79 - .../DataCatalog/Lineage/V1/Run_State.php | 16 - .../Lineage/V1/SearchLinksRequest.php | 245 -- .../Lineage/V1/SearchLinksResponse.php | 110 - .../Lineage/V1/UpdateProcessRequest.php | 182 -- .../Lineage/V1/UpdateRunRequest.php | 159 - .../batch_search_link_processes.php | 99 - .../V1/LineageClient/create_lineage_event.php | 73 - .../V1/LineageClient/create_process.php | 74 - .../samples/V1/LineageClient/create_run.php | 80 - .../V1/LineageClient/delete_lineage_event.php | 75 - .../V1/LineageClient/delete_process.php | 80 - .../samples/V1/LineageClient/delete_run.php | 80 - .../V1/LineageClient/get_lineage_event.php | 77 - .../samples/V1/LineageClient/get_process.php | 71 - .../v1/samples/V1/LineageClient/get_run.php | 71 - .../V1/LineageClient/list_lineage_events.php | 77 - .../V1/LineageClient/list_processes.php | 78 - .../v1/samples/V1/LineageClient/list_runs.php | 77 - .../samples/V1/LineageClient/search_links.php | 84 - .../V1/LineageClient/update_process.php | 59 - .../samples/V1/LineageClient/update_run.php | 76 - .../v1/src/V1/Gapic/LineageGapicClient.php | 1363 -------- .../v1/src/V1/LineageClient.php | 34 - .../v1/src/V1/gapic_metadata.json | 98 - .../V1/resources/lineage_client_config.json | 114 - .../resources/lineage_descriptor_config.php | 262 -- .../resources/lineage_rest_client_config.php | 240 -- .../v1/tests/Unit/V1/LineageClientTest.php | 1232 ------- .../Google/Cloud/Datafusion/V1/Datafusion.php | Bin 6980 -> 0 bytes .../Cloud/DataFusion/V1/Accelerator.php | 101 - .../V1/Accelerator/AcceleratorType.php | 75 - .../Cloud/DataFusion/V1/Accelerator/State.php | 72 - .../V1/Accelerator_AcceleratorType.php | 16 - .../Cloud/DataFusion/V1/Accelerator_State.php | 16 - .../DataFusion/V1/CreateInstanceRequest.php | 168 - .../Cloud/DataFusion/V1/CryptoKeyConfig.php | 76 - .../DataFusion/V1/DataFusionGrpcClient.php | 144 - .../DataFusion/V1/DeleteInstanceRequest.php | 86 - .../DataFusion/V1/GetInstanceRequest.php | 71 - .../Google/Cloud/DataFusion/V1/Instance.php | 1086 ------- .../DataFusion/V1/Instance/DisabledReason.php | 57 - .../Cloud/DataFusion/V1/Instance/State.php | 121 - .../Cloud/DataFusion/V1/Instance/Type.php | 80 - .../DataFusion/V1/Instance_DisabledReason.php | 16 - .../Cloud/DataFusion/V1/Instance_State.php | 16 - .../Cloud/DataFusion/V1/Instance_Type.php | 16 - .../V1/ListAvailableVersionsRequest.php | 200 -- .../V1/ListAvailableVersionsResponse.php | 105 - .../DataFusion/V1/ListInstancesRequest.php | 219 -- .../DataFusion/V1/ListInstancesResponse.php | 139 - .../Cloud/DataFusion/V1/NetworkConfig.php | 126 - .../Cloud/DataFusion/V1/OperationMetadata.php | 349 -- .../DataFusion/V1/RestartInstanceRequest.php | 71 - .../DataFusion/V1/UpdateInstanceRequest.php | 173 - .../Google/Cloud/DataFusion/V1/Version.php | 170 - .../Cloud/DataFusion/V1/Version/Type.php | 64 - .../Cloud/DataFusion/V1/Version_Type.php | 16 - .../V1/DataFusionClient/create_instance.php | 87 - .../V1/DataFusionClient/delete_instance.php | 81 - .../V1/DataFusionClient/get_instance.php | 72 - .../list_available_versions.php | 78 - .../V1/DataFusionClient/list_instances.php | 79 - .../V1/DataFusionClient/restart_instance.php | 85 - .../V1/DataFusionClient/update_instance.php | 85 - .../DataFusion/v1/src/V1/DataFusionClient.php | 34 - .../v1/src/V1/Gapic/DataFusionGapicClient.php | 860 ----- .../DataFusion/v1/src/V1/gapic_metadata.json | 53 - .../resources/data_fusion_client_config.json | 67 - .../data_fusion_descriptor_config.php | 142 - .../data_fusion_rest_client_config.php | 201 -- .../v1/tests/Unit/V1/DataFusionClientTest.php | 876 ----- .../Cloud/Datalabeling/V1Beta1/Annotation.php | Bin 6038 -> 0 bytes .../V1Beta1/AnnotationSpecSet.php | 38 - .../V1Beta1/DataLabelingService.php | Bin 17166 -> 0 bytes .../Datalabeling/V1Beta1/DataPayloads.php | 47 - .../Cloud/Datalabeling/V1Beta1/Dataset.php | Bin 5687 -> 0 bytes .../Cloud/Datalabeling/V1Beta1/Evaluation.php | Bin 3375 -> 0 bytes .../Datalabeling/V1Beta1/EvaluationJob.php | Bin 3264 -> 0 bytes .../V1Beta1/HumanAnnotationConfig.php | Bin 2797 -> 0 bytes .../Datalabeling/V1Beta1/Instruction.php | 46 - .../Cloud/Datalabeling/V1Beta1/Operations.php | Bin 5092 -> 0 bytes .../DataLabeling/V1beta1/AnnotatedDataset.php | 475 --- .../V1beta1/AnnotatedDatasetMetadata.php | 420 --- .../Cloud/DataLabeling/V1beta1/Annotation.php | 237 -- .../V1beta1/AnnotationMetadata.php | 77 - .../V1beta1/AnnotationSentiment.php | 57 - .../DataLabeling/V1beta1/AnnotationSource.php | 53 - .../DataLabeling/V1beta1/AnnotationSpec.php | 108 - .../V1beta1/AnnotationSpecSet.php | 225 -- .../DataLabeling/V1beta1/AnnotationType.php | 136 - .../DataLabeling/V1beta1/AnnotationValue.php | 351 -- .../Cloud/DataLabeling/V1beta1/Attempt.php | 104 - .../DataLabeling/V1beta1/BigQuerySource.php | 109 - .../V1beta1/BoundingBoxEvaluationOptions.php | 83 - .../DataLabeling/V1beta1/BoundingPoly.php | 67 - .../V1beta1/BoundingPolyConfig.php | 101 - .../V1beta1/ClassificationMetadata.php | 67 - .../V1beta1/ClassificationMetrics.php | 125 - .../DataLabeling/V1beta1/ConfusionMatrix.php | 62 - .../ConfusionMatrix/ConfusionMatrixEntry.php | 116 - .../V1beta1/ConfusionMatrix/Row.php | 119 - .../ConfusionMatrix_ConfusionMatrixEntry.php | 16 - .../V1beta1/ConfusionMatrix_Row.php | 16 - .../CreateAnnotationSpecSetRequest.php | 142 - .../V1beta1/CreateDatasetRequest.php | 132 - .../V1beta1/CreateEvaluationJobRequest.php | 132 - .../V1beta1/CreateInstructionMetadata.php | 157 - .../V1beta1/CreateInstructionRequest.php | 132 - .../DataLabeling/V1beta1/CsvInstruction.php | 68 - .../Cloud/DataLabeling/V1beta1/DataItem.php | 179 -- .../V1beta1/DataLabelingServiceGrpcClient.php | 566 ---- .../Cloud/DataLabeling/V1beta1/DataType.php | 69 - .../Cloud/DataLabeling/V1beta1/Dataset.php | 302 -- .../V1beta1/DeleteAnnotatedDatasetRequest.php | 75 - .../DeleteAnnotationSpecSetRequest.php | 86 - .../V1beta1/DeleteDatasetRequest.php | 86 - .../V1beta1/DeleteEvaluationJobRequest.php | 87 - .../V1beta1/DeleteInstructionRequest.php | 86 - .../Cloud/DataLabeling/V1beta1/Evaluation.php | 348 -- .../DataLabeling/V1beta1/EvaluationConfig.php | 82 - .../DataLabeling/V1beta1/EvaluationJob.php | 496 --- .../V1beta1/EvaluationJob/State.php | 104 - .../V1beta1/EvaluationJobAlertConfig.php | 118 - .../V1beta1/EvaluationJobConfig.php | 620 ---- .../V1beta1/EvaluationJob_State.php | 16 - .../V1beta1/EvaluationMetrics.php | 96 - .../DataLabeling/V1beta1/EventConfig.php | 75 - .../Cloud/DataLabeling/V1beta1/Example.php | 222 -- .../V1beta1/ExportDataOperationMetadata.php | 157 - .../V1beta1/ExportDataOperationResponse.php | 227 -- .../V1beta1/ExportDataRequest.php | 263 -- .../DataLabeling/V1beta1/GcsDestination.php | 110 - .../V1beta1/GcsFolderDestination.php | 67 - .../Cloud/DataLabeling/V1beta1/GcsSource.php | 105 - .../V1beta1/GetAnnotatedDatasetRequest.php | 91 - .../V1beta1/GetAnnotationSpecSetRequest.php | 86 - .../V1beta1/GetDataItemRequest.php | 86 - .../V1beta1/GetDatasetRequest.php | 86 - .../V1beta1/GetEvaluationJobRequest.php | 87 - .../V1beta1/GetEvaluationRequest.php | 87 - .../V1beta1/GetExampleRequest.php | 137 - .../V1beta1/GetInstructionRequest.php | 86 - .../V1beta1/HumanAnnotationConfig.php | 417 --- .../V1beta1/ImageBoundingPolyAnnotation.php | 143 - .../V1beta1/ImageClassificationAnnotation.php | 77 - .../V1beta1/ImageClassificationConfig.php | 139 - .../DataLabeling/V1beta1/ImagePayload.php | 169 - .../V1beta1/ImagePolylineAnnotation.php | 142 - .../V1beta1/ImageSegmentationAnnotation.php | 143 - .../V1beta1/ImportDataOperationMetadata.php | 157 - .../V1beta1/ImportDataOperationResponse.php | 135 - .../V1beta1/ImportDataRequest.php | 170 - .../DataLabeling/V1beta1/InputConfig.php | 281 -- .../DataLabeling/V1beta1/Instruction.php | 419 --- ...LabelImageBoundingBoxOperationMetadata.php | 77 - ...abelImageBoundingPolyOperationMetadata.php | 77 - ...elImageClassificationOperationMetadata.php | 77 - ...geOrientedBoundingBoxOperationMetadata.php | 77 - .../LabelImagePolylineOperationMetadata.php | 77 - .../V1beta1/LabelImageRequest.php | 334 -- .../V1beta1/LabelImageRequest/Feature.php | 94 - .../V1beta1/LabelImageRequest_Feature.php | 16 - ...abelImageSegmentationOperationMetadata.php | 77 - .../V1beta1/LabelOperationMetadata.php | 559 ---- .../Cloud/DataLabeling/V1beta1/LabelStats.php | 83 - ...belTextClassificationOperationMetadata.php | 77 - ...lTextEntityExtractionOperationMetadata.php | 77 - .../DataLabeling/V1beta1/LabelTextRequest.php | 256 -- .../V1beta1/LabelTextRequest/Feature.php | 62 - .../V1beta1/LabelTextRequest_Feature.php | 16 - ...elVideoClassificationOperationMetadata.php | 77 - .../LabelVideoEventOperationMetadata.php | 77 - ...lVideoObjectDetectionOperationMetadata.php | 77 - ...elVideoObjectTrackingOperationMetadata.php | 77 - .../V1beta1/LabelVideoRequest.php | 334 -- .../V1beta1/LabelVideoRequest/Feature.php | 76 - .../V1beta1/LabelVideoRequest_Feature.php | 16 - .../V1beta1/ListAnnotatedDatasetsRequest.php | 210 -- .../V1beta1/ListAnnotatedDatasetsResponse.php | 101 - .../V1beta1/ListAnnotationSpecSetsRequest.php | 210 -- .../ListAnnotationSpecSetsResponse.php | 101 - .../V1beta1/ListDataItemsRequest.php | 210 -- .../V1beta1/ListDataItemsResponse.php | 101 - .../V1beta1/ListDatasetsRequest.php | 210 -- .../V1beta1/ListDatasetsResponse.php | 101 - .../V1beta1/ListEvaluationJobsRequest.php | 245 -- .../V1beta1/ListEvaluationJobsResponse.php | 101 - .../V1beta1/ListExamplesRequest.php | 220 -- .../V1beta1/ListExamplesResponse.php | 101 - .../V1beta1/ListInstructionsRequest.php | 210 -- .../V1beta1/ListInstructionsResponse.php | 101 - .../V1beta1/NormalizedBoundingPoly.php | 67 - .../V1beta1/NormalizedPolyline.php | 67 - .../DataLabeling/V1beta1/NormalizedVertex.php | 103 - .../V1beta1/ObjectDetectionConfig.php | 105 - .../V1beta1/ObjectDetectionMetrics.php | 77 - .../V1beta1/ObjectTrackingConfig.php | 67 - .../V1beta1/ObjectTrackingFrame.php | 142 - .../DataLabeling/V1beta1/OperatorMetadata.php | 177 - .../DataLabeling/V1beta1/OutputConfig.php | 114 - .../V1beta1/PauseEvaluationJobRequest.php | 87 - .../DataLabeling/V1beta1/PdfInstruction.php | 67 - .../Cloud/DataLabeling/V1beta1/Polyline.php | 67 - .../DataLabeling/V1beta1/PolylineConfig.php | 101 - .../Cloud/DataLabeling/V1beta1/PrCurve.php | 193 -- .../PrCurve/ConfidenceMetricsEntry.php | 406 --- .../PrCurve_ConfidenceMetricsEntry.php | 16 - .../V1beta1/ResumeEvaluationJobRequest.php | 87 - .../V1beta1/SearchEvaluationsRequest.php | 352 -- .../V1beta1/SearchEvaluationsResponse.php | 101 - .../SearchExampleComparisonsRequest.php | 184 -- .../SearchExampleComparisonsResponse.php | 101 - .../ExampleComparison.php | 115 - ...eComparisonsResponse_ExampleComparison.php | 16 - .../V1beta1/SegmentationConfig.php | 105 - .../DataLabeling/V1beta1/SentimentConfig.php | 75 - .../V1beta1/SequentialSegment.php | 101 - .../V1beta1/StringAggregationType.php | 64 - .../V1beta1/TextClassificationAnnotation.php | 77 - .../V1beta1/TextClassificationConfig.php | 149 - .../TextEntityExtractionAnnotation.php | 121 - .../V1beta1/TextEntityExtractionConfig.php | 67 - .../DataLabeling/V1beta1/TextMetadata.php | 75 - .../DataLabeling/V1beta1/TextPayload.php | 67 - .../DataLabeling/V1beta1/TimeSegment.php | 129 - .../V1beta1/UpdateEvaluationJobRequest.php | 168 - .../Cloud/DataLabeling/V1beta1/Vertex.php | 102 - .../V1beta1/VideoClassificationAnnotation.php | 121 - .../V1beta1/VideoClassificationConfig.php | 125 - .../AnnotationSpecSetConfig.php | 108 - ...ficationConfig_AnnotationSpecSetConfig.php | 16 - .../V1beta1/VideoEventAnnotation.php | 121 - .../V1beta1/VideoObjectTrackingAnnotation.php | 155 - .../DataLabeling/V1beta1/VideoPayload.php | 203 -- .../DataLabeling/V1beta1/VideoThumbnail.php | 115 - .../create_annotation_spec_set.php | 74 - .../create_dataset.php | 74 - .../create_evaluation_job.php | 74 - .../create_instruction.php | 86 - .../delete_annotated_dataset.php | 75 - .../delete_annotation_spec_set.php | 73 - .../delete_dataset.php | 70 - .../delete_evaluation_job.php | 71 - .../delete_instruction.php | 70 - .../DataLabelingServiceClient/export_data.php | 99 - .../get_annotated_dataset.php | 77 - .../get_annotation_spec_set.php | 75 - .../get_data_item.php | 73 - .../DataLabelingServiceClient/get_dataset.php | 72 - .../get_evaluation.php | 78 - .../get_evaluation_job.php | 73 - .../DataLabelingServiceClient/get_example.php | 78 - .../get_instruction.php | 72 - .../DataLabelingServiceClient/import_data.php | 91 - .../DataLabelingServiceClient/label_image.php | 109 - .../DataLabelingServiceClient/label_text.php | 109 - .../DataLabelingServiceClient/label_video.php | 109 - .../list_annotated_datasets.php | 77 - .../list_annotation_spec_sets.php | 77 - .../list_data_items.php | 78 - .../list_datasets.php | 77 - .../list_evaluation_jobs.php | 78 - .../list_examples.php | 80 - .../list_instructions.php | 77 - .../pause_evaluation_job.php | 72 - .../resume_evaluation_job.php | 72 - .../search_evaluations.php | 81 - .../search_example_comparisons.php | 85 - .../update_evaluation_job.php | 64 - .../src/V1beta1/DataLabelingServiceClient.php | 36 - .../Gapic/DataLabelingServiceGapicClient.php | 2731 ---------------- .../v1beta1/src/V1beta1/gapic_metadata.json | 188 -- .../data_labeling_service_client_config.json | 215 -- ...ata_labeling_service_descriptor_config.php | 542 ---- ...ta_labeling_service_rest_client_config.php | 443 --- .../V1beta1/DataLabelingServiceClientTest.php | 2710 ---------------- .../Google/Dataflow/V1Beta3/Environment.php | Bin 4684 -> 0 bytes .../Google/Dataflow/V1Beta3/Jobs.php | Bin 9121 -> 0 bytes .../Google/Dataflow/V1Beta3/Messages.php | Bin 3094 -> 0 bytes .../Google/Dataflow/V1Beta3/Metrics.php | Bin 4643 -> 0 bytes .../Google/Dataflow/V1Beta3/Snapshots.php | Bin 3089 -> 0 bytes .../Google/Dataflow/V1Beta3/Streaming.php | Bin 2857 -> 0 bytes .../Google/Dataflow/V1Beta3/Templates.php | Bin 8211 -> 0 bytes .../Dataflow/V1beta3/AutoscalingAlgorithm.php | 64 - .../Dataflow/V1beta3/AutoscalingEvent.php | 270 -- .../AutoscalingEvent/AutoscalingEventType.php | 88 - .../AutoscalingEvent_AutoscalingEventType.php | 16 - .../Dataflow/V1beta3/AutoscalingSettings.php | 101 - .../Dataflow/V1beta3/BigQueryIODetails.php | 169 - .../Dataflow/V1beta3/BigTableIODetails.php | 135 - .../V1beta3/CheckActiveJobsRequest.php | 67 - .../V1beta3/CheckActiveJobsResponse.php | 67 - .../Dataflow/V1beta3/ComputationTopology.php | 237 -- .../Cloud/Dataflow/V1beta3/ContainerSpec.php | 199 -- .../V1beta3/CreateJobFromTemplateRequest.php | 269 -- .../Dataflow/V1beta3/CreateJobRequest.php | 221 -- .../Dataflow/V1beta3/CustomSourceLocation.php | 67 - .../Dataflow/V1beta3/DataDiskAssignment.php | 117 - .../Dataflow/V1beta3/DatastoreIODetails.php | 101 - .../Cloud/Dataflow/V1beta3/DebugOptions.php | 71 - .../Dataflow/V1beta3/DefaultPackageSet.php | 69 - .../V1beta3/DeleteSnapshotRequest.php | 135 - .../V1beta3/DeleteSnapshotResponse.php | 33 - .../Google/Cloud/Dataflow/V1beta3/Disk.php | 195 -- .../Cloud/Dataflow/V1beta3/DisplayData.php | 483 --- .../V1beta3/DynamicTemplateLaunchParams.php | 109 - .../Cloud/Dataflow/V1beta3/Environment.php | 809 ----- .../Dataflow/V1beta3/ExecutionStageState.php | 145 - .../V1beta3/ExecutionStageSummary.php | 307 -- .../ExecutionStageSummary/ComponentSource.php | 143 - .../ComponentTransform.php | 142 - .../ExecutionStageSummary/StageSource.php | 176 - .../ExecutionStageSummary_ComponentSource.php | 16 - ...ecutionStageSummary_ComponentTransform.php | 16 - .../ExecutionStageSummary_StageSource.php | 16 - .../Cloud/Dataflow/V1beta3/ExecutionState.php | 82 - .../Cloud/Dataflow/V1beta3/FailedLocation.php | 77 - .../Cloud/Dataflow/V1beta3/FileIODetails.php | 67 - .../V1beta3/FlexResourceSchedulingGoal.php | 61 - .../FlexTemplateRuntimeEnvironment.php | 967 ------ .../FlexTemplatesServiceGrpcClient.php | 50 - .../V1beta3/GetJobExecutionDetailsRequest.php | 227 -- .../Dataflow/V1beta3/GetJobMetricsRequest.php | 191 -- .../Cloud/Dataflow/V1beta3/GetJobRequest.php | 177 - .../Dataflow/V1beta3/GetSnapshotRequest.php | 135 - .../GetStageExecutionDetailsRequest.php | 350 -- .../Dataflow/V1beta3/GetTemplateRequest.php | 191 -- .../GetTemplateRequest/TemplateView.php | 51 - .../GetTemplateRequest_TemplateView.php | 16 - .../Dataflow/V1beta3/GetTemplateResponse.php | 207 -- .../GetTemplateResponse/TemplateType.php | 64 - .../GetTemplateResponse_TemplateType.php | 16 - .../V1beta3/InvalidTemplateParameters.php | 68 - .../ParameterViolation.php | 104 - ...dTemplateParameters_ParameterViolation.php | 16 - .../src/Google/Cloud/Dataflow/V1beta3/Job.php | 1209 ------- .../Dataflow/V1beta3/JobExecutionDetails.php | 109 - .../Dataflow/V1beta3/JobExecutionInfo.php | 68 - .../V1beta3/JobExecutionStageInfo.php | 76 - .../Cloud/Dataflow/V1beta3/JobMessage.php | 179 -- .../Dataflow/V1beta3/JobMessageImportance.php | 100 - .../Cloud/Dataflow/V1beta3/JobMetadata.php | 282 -- .../Cloud/Dataflow/V1beta3/JobMetrics.php | 116 - .../Cloud/Dataflow/V1beta3/JobState.php | 163 - .../Google/Cloud/Dataflow/V1beta3/JobType.php | 66 - .../Google/Cloud/Dataflow/V1beta3/JobView.php | 73 - .../V1beta3/JobsV1Beta3GrpcClient.php | 166 - .../V1beta3/KeyRangeDataDiskAssignment.php | 150 - .../Dataflow/V1beta3/KeyRangeLocation.php | 230 -- .../Cloud/Dataflow/V1beta3/KindType.php | 103 - .../V1beta3/LaunchFlexTemplateParameter.php | 353 -- .../V1beta3/LaunchFlexTemplateRequest.php | 191 -- .../V1beta3/LaunchFlexTemplateResponse.php | 81 - .../V1beta3/LaunchTemplateParameters.php | 221 -- .../V1beta3/LaunchTemplateRequest.php | 276 -- .../V1beta3/LaunchTemplateResponse.php | 81 - .../V1beta3/ListJobMessagesRequest.php | 360 --- .../V1beta3/ListJobMessagesResponse.php | 135 - .../Dataflow/V1beta3/ListJobsRequest.php | 266 -- .../V1beta3/ListJobsRequest/Filter.php | 77 - .../V1beta3/ListJobsRequest_Filter.php | 16 - .../Dataflow/V1beta3/ListJobsResponse.php | 147 - .../Dataflow/V1beta3/ListSnapshotsRequest.php | 135 - .../V1beta3/ListSnapshotsResponse.php | 67 - .../V1beta3/MessagesV1Beta3GrpcClient.php | 57 - .../Dataflow/V1beta3/MetricStructuredName.php | 156 - .../Cloud/Dataflow/V1beta3/MetricUpdate.php | 585 ---- .../V1beta3/MetricsV1Beta3GrpcClient.php | 92 - .../Dataflow/V1beta3/MountedDataDisk.php | 79 - .../Google/Cloud/Dataflow/V1beta3/Package.php | 120 - .../Dataflow/V1beta3/ParameterMetadata.php | 275 -- .../Cloud/Dataflow/V1beta3/ParameterType.php | 114 - .../Dataflow/V1beta3/PipelineDescription.php | 137 - .../Dataflow/V1beta3/ProgressTimeseries.php | 105 - .../V1beta3/ProgressTimeseries/Point.php | 114 - .../V1beta3/ProgressTimeseries_Point.php | 16 - .../Dataflow/V1beta3/PubSubIODetails.php | 101 - .../Cloud/Dataflow/V1beta3/PubsubLocation.php | 292 -- .../V1beta3/PubsubSnapshotMetadata.php | 145 - .../Dataflow/V1beta3/RuntimeEnvironment.php | 697 ---- .../Dataflow/V1beta3/RuntimeMetadata.php | 111 - .../Google/Cloud/Dataflow/V1beta3/SDKInfo.php | 101 - .../Dataflow/V1beta3/SDKInfo/Language.php | 64 - .../Dataflow/V1beta3/SDKInfo_Language.php | 16 - .../V1beta3/SdkHarnessContainerImage.php | 193 -- .../Cloud/Dataflow/V1beta3/SdkVersion.php | 135 - .../V1beta3/SdkVersion/SdkSupportStatus.php | 79 - .../V1beta3/SdkVersion_SdkSupportStatus.php | 16 - .../Cloud/Dataflow/V1beta3/ShuffleMode.php | 64 - .../Cloud/Dataflow/V1beta3/Snapshot.php | 397 --- .../Dataflow/V1beta3/SnapshotJobRequest.php | 247 -- .../Cloud/Dataflow/V1beta3/SnapshotState.php | 83 - .../V1beta3/SnapshotsV1Beta3GrpcClient.php | 80 - .../Dataflow/V1beta3/SpannerIODetails.php | 135 - .../V1beta3/StageExecutionDetails.php | 109 - .../Cloud/Dataflow/V1beta3/StageSummary.php | 279 -- .../Dataflow/V1beta3/StateFamilyConfig.php | 101 - .../Google/Cloud/Dataflow/V1beta3/Step.php | 173 - .../Cloud/Dataflow/V1beta3/StreamLocation.php | 178 - .../StreamingApplianceSnapshotConfig.php | 101 - .../V1beta3/StreamingComputationRanges.php | 102 - .../V1beta3/StreamingSideInputLocation.php | 101 - .../V1beta3/StreamingStageLocation.php | 72 - .../Dataflow/V1beta3/StructuredMessage.php | 141 - .../V1beta3/StructuredMessage/Parameter.php | 114 - .../V1beta3/StructuredMessage_Parameter.php | 16 - .../Dataflow/V1beta3/TaskRunnerSettings.php | 769 ----- .../Cloud/Dataflow/V1beta3/TeardownPolicy.php | 71 - .../Dataflow/V1beta3/TemplateMetadata.php | 135 - .../V1beta3/TemplatesServiceGrpcClient.php | 80 - .../Cloud/Dataflow/V1beta3/TopologyConfig.php | 204 -- .../Dataflow/V1beta3/TransformSummary.php | 237 -- .../Dataflow/V1beta3/UpdateJobRequest.php | 191 -- .../Dataflow/V1beta3/WorkItemDetails.php | 309 -- .../Cloud/Dataflow/V1beta3/WorkerDetails.php | 101 - .../V1beta3/WorkerIPAddressConfiguration.php | 61 - .../Cloud/Dataflow/V1beta3/WorkerPool.php | 951 ------ .../Cloud/Dataflow/V1beta3/WorkerSettings.php | 289 -- .../launch_flex_template.php | 57 - .../aggregated_list_jobs.php | 62 - .../JobsV1Beta3Client/check_active_jobs.php | 57 - .../V1beta3/JobsV1Beta3Client/create_job.php | 63 - .../V1beta3/JobsV1Beta3Client/get_job.php | 63 - .../V1beta3/JobsV1Beta3Client/list_jobs.php | 69 - .../JobsV1Beta3Client/snapshot_job.php | 57 - .../V1beta3/JobsV1Beta3Client/update_job.php | 63 - .../list_job_messages.php | 68 - .../get_job_execution_details.php | 64 - .../MetricsV1Beta3Client/get_job_metrics.php | 63 - .../get_stage_execution_details.php | 65 - .../delete_snapshot.php | 57 - .../SnapshotsV1Beta3Client/get_snapshot.php | 57 - .../SnapshotsV1Beta3Client/list_snapshots.php | 57 - .../create_job_from_template.php | 57 - .../TemplatesServiceClient/get_template.php | 57 - .../launch_template.php | 57 - .../V1beta3/FlexTemplatesServiceClient.php | 36 - .../Gapic/FlexTemplatesServiceGapicClient.php | 228 -- .../V1beta3/Gapic/JobsV1Beta3GapicClient.php | 724 ----- .../Gapic/MessagesV1Beta3GapicClient.php | 291 -- .../Gapic/MetricsV1Beta3GapicClient.php | 454 --- .../Gapic/SnapshotsV1Beta3GapicClient.php | 339 -- .../Gapic/TemplatesServiceGapicClient.php | 396 --- .../v1beta3/src/V1beta3/JobsV1Beta3Client.php | 36 - .../src/V1beta3/MessagesV1Beta3Client.php | 36 - .../src/V1beta3/MetricsV1Beta3Client.php | 36 - .../src/V1beta3/SnapshotsV1Beta3Client.php | 36 - .../src/V1beta3/TemplatesServiceClient.php | 36 - .../v1beta3/src/V1beta3/gapic_metadata.json | 153 - .../flex_templates_service_client_config.json | 27 - ...ex_templates_service_descriptor_config.php | 26 - ...x_templates_service_rest_client_config.php | 26 - .../jobs_v1_beta3_client_config.json | 67 - .../jobs_v1_beta3_descriptor_config.php | 148 - .../jobs_v1_beta3_rest_client_config.php | 151 - .../messages_v1_beta3_client_config.json | 37 - .../messages_v1_beta3_descriptor_config.php | 40 - .../messages_v1_beta3_rest_client_config.php | 36 - .../metrics_v1_beta3_client_config.json | 47 - .../metrics_v1_beta3_descriptor_config.php | 102 - .../metrics_v1_beta3_rest_client_config.php | 83 - .../snapshots_v1_beta3_client_config.json | 47 - .../snapshots_v1_beta3_descriptor_config.php | 80 - .../snapshots_v1_beta3_rest_client_config.php | 94 - .../templates_service_client_config.json | 47 - .../templates_service_descriptor_config.php | 62 - .../templates_service_rest_client_config.php | 79 - .../FlexTemplatesServiceClientTest.php | 113 - .../Unit/V1beta3/JobsV1Beta3ClientTest.php | 522 --- .../V1beta3/MessagesV1Beta3ClientTest.php | 124 - .../Unit/V1beta3/MetricsV1Beta3ClientTest.php | 241 -- .../V1beta3/SnapshotsV1Beta3ClientTest.php | 231 -- .../V1beta3/TemplatesServiceClientTest.php | 239 -- 2237 files changed, 9226 insertions(+), 249296 deletions(-) rename {owl-bot-staging/ApiKeys/v2 => ApiKeys}/src/V2/Client/ApiKeysClient.php (100%) rename {owl-bot-staging/ApiKeys/v2 => ApiKeys}/src/V2/Client/BaseClient/ApiKeysBaseClient.php (100%) rename {owl-bot-staging/ApiKeys/v2 => ApiKeys}/tests/Unit/V2/Client/ApiKeysClientTest.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/src/V1/Client/BaseClient/ProvisioningBaseClient.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/src/V1/Client/BaseClient/RegistryBaseClient.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/src/V1/Client/ProvisioningClient.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/src/V1/Client/RegistryClient.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/tests/Unit/V1/Client/ProvisioningClientTest.php (100%) rename {owl-bot-staging/ApigeeRegistry/v1 => ApigeeRegistry}/tests/Unit/V1/Client/RegistryClientTest.php (100%) rename {owl-bot-staging/BareMetalSolution/v2 => BareMetalSolution}/src/V2/Client/BareMetalSolutionClient.php (100%) rename {owl-bot-staging/BareMetalSolution/v2 => BareMetalSolution}/src/V2/Client/BaseClient/BareMetalSolutionBaseClient.php (100%) rename {owl-bot-staging/BareMetalSolution/v2 => BareMetalSolution}/tests/Unit/V2/Client/BareMetalSolutionClientTest.php (100%) rename {owl-bot-staging/Batch/v1 => Batch}/src/V1/Client/BaseClient/BatchServiceBaseClient.php (100%) rename {owl-bot-staging/Batch/v1 => Batch}/src/V1/Client/BatchServiceClient.php (100%) rename {owl-bot-staging/Batch/v1 => Batch}/tests/Unit/V1/Client/BatchServiceClientTest.php (100%) rename {owl-bot-staging/BeyondCorpAppConnections/v1 => BeyondCorpAppConnections}/src/V1/Client/AppConnectionsServiceClient.php (100%) rename {owl-bot-staging/BeyondCorpAppConnections/v1 => BeyondCorpAppConnections}/src/V1/Client/BaseClient/AppConnectionsServiceBaseClient.php (100%) rename {owl-bot-staging/BeyondCorpAppConnections/v1 => BeyondCorpAppConnections}/tests/Unit/V1/Client/AppConnectionsServiceClientTest.php (100%) rename {owl-bot-staging/BeyondCorpAppConnectors/v1 => BeyondCorpAppConnectors}/src/V1/Client/AppConnectorsServiceClient.php (100%) rename {owl-bot-staging/BeyondCorpAppConnectors/v1 => BeyondCorpAppConnectors}/src/V1/Client/BaseClient/AppConnectorsServiceBaseClient.php (100%) rename {owl-bot-staging/BeyondCorpAppConnectors/v1 => BeyondCorpAppConnectors}/tests/Unit/V1/Client/AppConnectorsServiceClientTest.php (100%) rename {owl-bot-staging/BeyondCorpAppGateways/v1 => BeyondCorpAppGateways}/src/V1/Client/AppGatewaysServiceClient.php (100%) rename {owl-bot-staging/BeyondCorpAppGateways/v1 => BeyondCorpAppGateways}/src/V1/Client/BaseClient/AppGatewaysServiceBaseClient.php (100%) rename {owl-bot-staging/BeyondCorpAppGateways/v1 => BeyondCorpAppGateways}/tests/Unit/V1/Client/AppGatewaysServiceClientTest.php (100%) rename {owl-bot-staging/BeyondCorpClientConnectorServices/v1 => BeyondCorpClientConnectorServices}/src/V1/Client/BaseClient/ClientConnectorServicesServiceBaseClient.php (100%) rename {owl-bot-staging/BeyondCorpClientConnectorServices/v1 => BeyondCorpClientConnectorServices}/src/V1/Client/ClientConnectorServicesServiceClient.php (100%) rename {owl-bot-staging/BeyondCorpClientConnectorServices/v1 => BeyondCorpClientConnectorServices}/tests/Unit/V1/Client/ClientConnectorServicesServiceClientTest.php (100%) rename {owl-bot-staging/BeyondCorpClientGateways/v1 => BeyondCorpClientGateways}/src/V1/Client/BaseClient/ClientGatewaysServiceBaseClient.php (100%) rename {owl-bot-staging/BeyondCorpClientGateways/v1 => BeyondCorpClientGateways}/src/V1/Client/ClientGatewaysServiceClient.php (100%) rename {owl-bot-staging/BeyondCorpClientGateways/v1 => BeyondCorpClientGateways}/tests/Unit/V1/Client/ClientGatewaysServiceClientTest.php (100%) rename {owl-bot-staging/BigQueryAnalyticsHub/v1 => BigQueryAnalyticsHub}/src/V1/Client/AnalyticsHubServiceClient.php (100%) rename {owl-bot-staging/BigQueryAnalyticsHub/v1 => BigQueryAnalyticsHub}/src/V1/Client/BaseClient/AnalyticsHubServiceBaseClient.php (100%) rename {owl-bot-staging/BigQueryAnalyticsHub/v1 => BigQueryAnalyticsHub}/tests/Unit/V1/Client/AnalyticsHubServiceClientTest.php (100%) rename {owl-bot-staging/BigQueryDataExchange/v1beta1 => BigQueryDataExchange}/src/V1beta1/Client/AnalyticsHubServiceClient.php (100%) rename {owl-bot-staging/BigQueryDataExchange/v1beta1 => BigQueryDataExchange}/src/V1beta1/Client/BaseClient/AnalyticsHubServiceBaseClient.php (100%) rename {owl-bot-staging/BigQueryDataExchange/v1beta1 => BigQueryDataExchange}/tests/Unit/V1beta1/Client/AnalyticsHubServiceClientTest.php (100%) rename {owl-bot-staging/BigQueryDataPolicies/v1 => BigQueryDataPolicies}/src/V1/Client/BaseClient/DataPolicyServiceBaseClient.php (100%) rename {owl-bot-staging/BigQueryDataPolicies/v1 => BigQueryDataPolicies}/src/V1/Client/DataPolicyServiceClient.php (100%) rename {owl-bot-staging/BigQueryDataPolicies/v1 => BigQueryDataPolicies}/tests/Unit/V1/Client/DataPolicyServiceClientTest.php (100%) rename {owl-bot-staging/BigQueryMigration/v2 => BigQueryMigration}/src/V2/Client/BaseClient/MigrationServiceBaseClient.php (100%) rename {owl-bot-staging/BigQueryMigration/v2 => BigQueryMigration}/src/V2/Client/MigrationServiceClient.php (100%) rename {owl-bot-staging/BigQueryMigration/v2 => BigQueryMigration}/tests/Unit/V2/Client/MigrationServiceClientTest.php (100%) rename {owl-bot-staging/Build/v2 => Build}/src/V2/Client/BaseClient/RepositoryManagerBaseClient.php (100%) rename {owl-bot-staging/Build/v2 => Build}/src/V2/Client/RepositoryManagerClient.php (100%) rename {owl-bot-staging/Build/v2 => Build}/tests/Unit/V2/Client/RepositoryManagerClientTest.php (100%) rename {owl-bot-staging/CertificateManager/v1 => CertificateManager}/src/V1/Client/BaseClient/CertificateManagerBaseClient.php (100%) rename {owl-bot-staging/CertificateManager/v1 => CertificateManager}/src/V1/Client/CertificateManagerClient.php (100%) rename {owl-bot-staging/CertificateManager/v1 => CertificateManager}/tests/Unit/V1/Client/CertificateManagerClientTest.php (100%) rename {owl-bot-staging/ConfidentialComputing/v1 => ConfidentialComputing}/src/V1/Client/BaseClient/ConfidentialComputingBaseClient.php (100%) rename {owl-bot-staging/ConfidentialComputing/v1 => ConfidentialComputing}/src/V1/Client/ConfidentialComputingClient.php (100%) rename {owl-bot-staging/ConfidentialComputing/v1 => ConfidentialComputing}/tests/Unit/V1/Client/ConfidentialComputingClientTest.php (100%) rename {owl-bot-staging/DataCatalogLineage/v1 => DataCatalogLineage}/src/V1/Client/BaseClient/LineageBaseClient.php (100%) rename {owl-bot-staging/DataCatalogLineage/v1 => DataCatalogLineage}/src/V1/Client/LineageClient.php (100%) rename {owl-bot-staging/DataCatalogLineage/v1 => DataCatalogLineage}/tests/Unit/V1/Client/LineageClientTest.php (100%) rename {owl-bot-staging/DataFusion/v1 => DataFusion}/src/V1/Client/BaseClient/DataFusionBaseClient.php (100%) rename {owl-bot-staging/DataFusion/v1 => DataFusion}/src/V1/Client/DataFusionClient.php (100%) rename {owl-bot-staging/DataFusion/v1 => DataFusion}/tests/Unit/V1/Client/DataFusionClientTest.php (100%) rename {owl-bot-staging/DataLabeling/v1beta1 => DataLabeling}/src/V1beta1/Client/BaseClient/DataLabelingServiceBaseClient.php (100%) rename {owl-bot-staging/DataLabeling/v1beta1 => DataLabeling}/src/V1beta1/Client/DataLabelingServiceClient.php (100%) rename {owl-bot-staging/DataLabeling/v1beta1 => DataLabeling}/tests/Unit/V1beta1/Client/DataLabelingServiceClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/FlexTemplatesServiceBaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/JobsV1Beta3BaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/MessagesV1Beta3BaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/MetricsV1Beta3BaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/SnapshotsV1Beta3BaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/BaseClient/TemplatesServiceBaseClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/FlexTemplatesServiceClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/JobsV1Beta3Client.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/MessagesV1Beta3Client.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/MetricsV1Beta3Client.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/SnapshotsV1Beta3Client.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/src/V1beta3/Client/TemplatesServiceClient.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/FlexTemplatesServiceClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/JobsV1Beta3ClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/MessagesV1Beta3ClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/MetricsV1Beta3ClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/SnapshotsV1Beta3ClientTest.php (100%) rename {owl-bot-staging/Dataflow/v1beta3 => Dataflow}/tests/Unit/V1beta3/Client/TemplatesServiceClientTest.php (100%) delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Apikeys.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Resources.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidApplication.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidKeyRestrictions.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiKeysGrpcClient.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiTarget.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/BrowserKeyRestrictions.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/CreateKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/DeleteKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringResponse.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/IosKeyRestrictions.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysResponse.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyResponse.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Restrictions.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ServerKeyRestrictions.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UndeleteKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UpdateKeyRequest.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/create_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/delete_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key_string.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/list_keys.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/lookup_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/undelete_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/update_key.php delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/ApiKeysClient.php delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/Gapic/ApiKeysGapicClient.php delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_client_config.json delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_descriptor_config.php delete mode 100644 owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_rest_client_config.php delete mode 100644 owl-bot-staging/ApiKeys/v2/tests/Unit/V2/ApiKeysClientTest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/GPBMetadata/Google/Cloud/Apigeeregistry/V1/ProvisioningService.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/GPBMetadata/Google/Cloud/Apigeeregistry/V1/RegistryModels.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/GPBMetadata/Google/Cloud/Apigeeregistry/V1/RegistryService.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Api.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiDeployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiSpec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiVersion.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Artifact.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiDeploymentRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiSpecRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiVersionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateArtifactRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateInstanceRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRevisionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRevisionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiVersionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteArtifactRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteInstanceRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiDeploymentRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecContentsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiVersionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactContentsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetInstanceRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/Config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/State.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance_Config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance_State.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentRevisionsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentRevisionsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsResponse.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ProvisioningGrpcClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RegistryGrpcClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ReplaceArtifactRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiDeploymentRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiSpecRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiDeploymentRevisionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiSpecRevisionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiDeploymentRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiSpecRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiVersionRequest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/create_instance.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/delete_instance.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_iam_policy.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_instance.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_location.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/list_locations.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/set_iam_policy.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_deployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_spec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_version.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_artifact.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment_revision.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec_revision.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_version.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_artifact.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_deployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec_contents.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_version.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact_contents.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_iam_policy.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_location.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployment_revisions.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployments.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_spec_revisions.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_specs.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_versions.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_apis.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_artifacts.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_locations.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/replace_artifact.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_deployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_spec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/set_iam_policy.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_deployment_revision.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_spec_revision.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_deployment.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_spec.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_version.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/ProvisioningGapicClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/RegistryGapicClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/ProvisioningClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/RegistryClient.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_client_config.json delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_descriptor_config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_rest_client_config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_client_config.json delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_descriptor_config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_rest_client_config.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/ProvisioningClientTest.php delete mode 100644 owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/RegistryClientTest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Baremetalsolution.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Lun.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Network.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/NfsShare.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Volume.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/BareMetalSolutionGrpcClient.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/DetachLunRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetInstanceRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetLunRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNetworkRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNfsShareRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetVolumeRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListInstancesRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListInstancesResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface/LogicalNetworkInterface.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface_LogicalNetworkInterface.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/MultiprotocolType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/StorageType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_MultiprotocolType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_StorageType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/Type.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkAddressReservation.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkUsage.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network_Type.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/AllowedClient.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/MountPermissions.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_AllowedClient.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_MountPermissions.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/OperationMetadata.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResizeVolumeRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface/InterfaceType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate_LogicalInterface.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate_LogicalInterface_InterfaceType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StartInstanceRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StartInstanceResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceResponse.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateInstanceRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNetworkRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNfsShareRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateVolumeRequest.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/QosPolicy.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/VlanAttachment.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_QosPolicy.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_VlanAttachment.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotAutoDeleteBehavior.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotReservationDetail.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/StorageType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_SnapshotAutoDeleteBehavior.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_SnapshotReservationDetail.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_State.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_StorageType.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/detach_lun.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_lun.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_network.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_nfs_share.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_volume.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_instances.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_luns.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_network_usage.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_networks.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_nfs_shares.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_volumes.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/reset_instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/resize_volume.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/start_instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/stop_instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_instance.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_network.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_nfs_share.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_volume.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/BareMetalSolutionClient.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/Gapic/BareMetalSolutionGapicClient.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_client_config.json delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_descriptor_config.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_rest_client_config.php delete mode 100644 owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/BareMetalSolutionClientTest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Batch.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Job.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Task.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Volume.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Accelerator.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/AttachedDisk.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Disk.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicyOrTemplate.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/LocationPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkInterface.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/ProvisioningModel.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_Accelerator.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_AttachedDisk.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_Disk.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_InstancePolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_InstancePolicyOrTemplate.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_LocationPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_NetworkInterface.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_NetworkPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_ProvisioningModel.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/BatchServiceGrpcClient.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ComputeResource.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/CreateJobRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/DeleteJobRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment/KMSEnvMap.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment_KMSEnvMap.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GCS.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetJobRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetTaskRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Job.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Message.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Type.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification_Message.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification_Type.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/InstanceStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/State.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/TaskGroupStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_InstanceStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_State.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_TaskGroupStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/Action.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/ActionCondition.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy_Action.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy_ActionCondition.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListJobsRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListJobsResponse.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksRequest.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksResponse.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy/Destination.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy_Destination.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/NFS.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Barrier.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Container.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Script.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Barrier.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Container.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Script.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ServiceAccount.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/StatusEvent.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Task.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskExecution.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskGroup.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskSpec.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus/State.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus_State.php delete mode 100644 owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Volume.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/create_job.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/delete_job.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_job.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_location.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_task.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_jobs.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_locations.php delete mode 100644 owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_tasks.php delete mode 100644 owl-bot-staging/Batch/v1/src/V1/BatchServiceClient.php delete mode 100644 owl-bot-staging/Batch/v1/src/V1/Gapic/BatchServiceGapicClient.php delete mode 100644 owl-bot-staging/Batch/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/Batch/v1/src/V1/resources/batch_service_client_config.json delete mode 100644 owl-bot-staging/Batch/v1/src/V1/resources/batch_service_descriptor_config.php delete mode 100644 owl-bot-staging/Batch/v1/src/V1/resources/batch_service_rest_client_config.php delete mode 100644 owl-bot-staging/Batch/v1/tests/Unit/V1/BatchServiceClientTest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnections/V1/AppConnectionsService.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/ApplicationEndpoint.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway/Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/State.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnectionOperationMetadata.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_ApplicationEndpoint.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_Gateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_Gateway_Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_State.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnectionsServiceGrpcClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/CreateAppConnectionRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/DeleteAppConnectionRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/GetAppConnectionRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsResponse.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse/AppConnectionDetails.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse_AppConnectionDetails.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/UpdateAppConnectionRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/create_app_connection.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/delete_app_connection.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_app_connection.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_location.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_app_connections.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/update_app_connection.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/AppConnectionsServiceClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/Gapic/AppConnectionsServiceGapicClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_client_config.json delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_descriptor_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_rest_client_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/AppConnectionsServiceClientTest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorInstanceConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorsService.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/ResourceInfo.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo/ServiceAccount.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/State.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorInstanceConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorOperationMetadata.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_PrincipalInfo.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_PrincipalInfo_ServiceAccount.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_State.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorsServiceGrpcClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/CreateAppConnectorRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/DeleteAppConnectorRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/GetAppConnectorRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/HealthStatus.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ImageConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsResponse.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig/CloudPubSubNotificationConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig_CloudPubSubNotificationConfig.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ReportStatusRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ResourceInfo.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/UpdateAppConnectorRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/create_app_connector.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/delete_app_connector.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_app_connector.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_location.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_app_connectors.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/report_status.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/update_app_connector.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/AppConnectorsServiceClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/Gapic/AppConnectorsServiceGapicClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_client_config.json delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_descriptor_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_rest_client_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/AppConnectorsServiceClientTest.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appgateways/V1/AppGatewaysService.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/AllocatedConnection.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/HostType.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/State.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGatewayOperationMetadata.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_AllocatedConnection.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_HostType.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_State.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_Type.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGatewaysServiceGrpcClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/CreateAppGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/DeleteAppGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/GetAppGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysRequest.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysResponse.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/create_app_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_app_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_location.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_app_gateways.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/AppGatewaysServiceClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/Gapic/AppGatewaysServiceGapicClient.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_client_config.json delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_descriptor_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_rest_client_config.php delete mode 100644 owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/AppGatewaysServiceClientTest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientconnectorservices/V1/ClientConnectorServicesService.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress/PeeredVpc.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/DestinationRoute.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/TransportProtocol.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/State.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorServiceOperationMetadata.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Egress.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Egress_PeeredVpc.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Ingress.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Ingress_Config.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Ingress_Config_DestinationRoute.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Ingress_Config_TransportProtocol.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_State.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorServicesServiceGrpcClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/CreateClientConnectorServiceRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/DeleteClientConnectorServiceRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/GetClientConnectorServiceRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesResponse.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/UpdateClientConnectorServiceRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_location.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/ClientConnectorServicesServiceClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/Gapic/ClientConnectorServicesServiceGapicClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_client_config.json delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_descriptor_config.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_rest_client_config.php delete mode 100644 owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/ClientConnectorServicesServiceClientTest.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientgateways/V1/ClientGatewaysService.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway/State.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGatewayOperationMetadata.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway_State.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGatewaysServiceGrpcClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/CreateClientGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/DeleteClientGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/GetClientGatewayRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysRequest.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysResponse.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_location.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/ClientGatewaysServiceClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/Gapic/ClientGatewaysServiceGapicClient.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_client_config.json delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_descriptor_config.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_rest_client_config.php delete mode 100644 owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/ClientGatewaysServiceClientTest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Analyticshub/V1/Analyticshub.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/AnalyticsHubServiceGrpcClient.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateListingRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataExchange.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataProvider.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteListingRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDataset.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDatasetReference.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetListingRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesResponse.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsResponse.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesResponse.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/BigQueryDatasetSource.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/Category.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/State.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_BigQueryDatasetSource.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_Category.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_State.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Publisher.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingResponse.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateListingRequest.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_listings.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_listing.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/AnalyticsHubServiceClient.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/Gapic/AnalyticsHubServiceGapicClient.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_client_config.json delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_descriptor_config.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_rest_client_config.php delete mode 100644 owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/AnalyticsHubServiceClientTest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Dataexchange/V1Beta1/Dataexchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/AnalyticsHubServiceGrpcClient.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateListingRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataExchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataProvider.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteListingRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDataset.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDatasetReference.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetListingRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesResponse.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsResponse.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesResponse.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/BigQueryDatasetSource.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/Category.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/State.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_BigQueryDatasetSource.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_Category.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_State.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Publisher.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingResponse.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateDataExchangeRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateListingRequest.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_location.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/AnalyticsHubServiceClient.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/Gapic/AnalyticsHubServiceGapicClient.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/gapic_metadata.json delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_client_config.json delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_descriptor_config.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_rest_client_config.php delete mode 100644 owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/AnalyticsHubServiceClientTest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1/Datapolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/CreateDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy/PredefinedExpression.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy_PredefinedExpression.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy/DataPolicyType.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicyServiceGrpcClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy_DataPolicyType.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DeleteDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/GetDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesResponse.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/RenameDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/UpdateDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/create_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/delete_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/list_data_policies.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/rename_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/update_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/DataPolicyServiceClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/Gapic/DataPolicyServiceGapicClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_client_config.json delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_descriptor_config.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_rest_client_config.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/DataPolicyServiceClientTest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1Beta1/Datapolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/CreateDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy/PredefinedExpression.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy_PredefinedExpression.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy/DataPolicyType.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicyServiceGrpcClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy_DataPolicyType.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DeleteDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/GetDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesResponse.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/UpdateDataPolicyRequest.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/create_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/delete_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/list_data_policies.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/update_data_policy.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/DataPolicyServiceClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/Gapic/DataPolicyServiceGapicClient.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/gapic_metadata.json delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_client_config.json delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_descriptor_config.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_rest_client_config.php delete mode 100644 owl-bot-staging/BigQueryDataPolicies/v1beta1/tests/Unit/V1beta1/DataPolicyServiceClientTest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationEntities.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationErrorDetails.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationMetrics.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationService.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/TranslationConfig.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/AzureSynapseDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/BigQueryDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/CreateMigrationWorkflowRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/DeleteMigrationWorkflowRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Dialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorDetail.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorLocation.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationSubtaskRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationWorkflowRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/HiveQLDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksResponse.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsResponse.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationServiceGrpcClient.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask/State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask_State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask/State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask_State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow/State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow_State.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MySQLDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey/Type.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey_Type.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingValue.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NetezzaDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMapping.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMappingList.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/OracleDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Point.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PostgresqlDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PrestoDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/RedshiftDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ResourceErrorDetail.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SQLServerDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SnowflakeDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SourceEnv.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SparkSQLDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/StartMigrationWorkflowRequest.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect/Mode.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect_Mode.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TimeInterval.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TimeSeries.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TranslationConfigDetails.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TypedValue.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/VerticaDialect.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/create_migration_workflow.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/delete_migration_workflow.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_subtask.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_workflow.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_subtasks.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_workflows.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/start_migration_workflow.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/Gapic/MigrationServiceGapicClient.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/MigrationServiceClient.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_client_config.json delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_descriptor_config.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_rest_client_config.php delete mode 100644 owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/MigrationServiceClientTest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V1/Cloudbuild.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult/Decision.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult_Decision.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApproveBuildRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ArtifactResult.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/ArtifactObjects.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/MavenArtifact.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/NpmPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/PythonPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_ArtifactObjects.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_MavenArtifact.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_NpmPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_PythonPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo/FailureType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Status.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning/Priority.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval/State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval_State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOperationMetadata.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/DefaultLogsBucketBehavior.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LogStreamingOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LoggingMode.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/MachineType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/PoolOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/SubstitutionOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/VerifyOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_DefaultLogsBucketBehavior.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_LogStreamingOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_LoggingMode.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_MachineType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_PoolOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_SubstitutionOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_VerifyOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildStep.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildTrigger.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_FailureInfo.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_FailureInfo_FailureType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_Status.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_Warning.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_Warning_Priority.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuiltImage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CancelBuildRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CloudBuildGrpcClient.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildTriggerRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolOperationMetadata.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteBuildTriggerRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolOperationMetadata.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/FileHashes.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildTriggerRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetWorkerPoolRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitHubEventsConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitSource.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash/HashType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash_HashType.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/InlineSecret.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersResponse.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsResponse.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsResponse.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig/EgressOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/WorkerConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_NetworkConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_NetworkConfig_EgressOption.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_WorkerConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig/State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig_State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter/CommentControl.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter_CommentControl.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PushFilter.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookResponse.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RepoSource.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Results.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RetryBuildRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RunBuildTriggerRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secret.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SecretManagerSecret.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secrets.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Source.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SourceProvenance.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSource.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSourceManifest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/TimeSpan.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateBuildTriggerRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolOperationMetadata.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolRequest.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedMavenArtifact.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedNpmPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedPythonPackage.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Volume.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig/State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig_State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool/State.php delete mode 100644 owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool_State.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/approve_build.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/cancel_build.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build_trigger.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_worker_pool.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_build_trigger.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_worker_pool.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build_trigger.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_worker_pool.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_build_triggers.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_builds.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_worker_pools.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/receive_trigger_webhook.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/retry_build.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/run_build_trigger.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_build_trigger.php delete mode 100644 owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_worker_pool.php delete mode 100644 owl-bot-staging/Build/v1/src/V1/CloudBuildClient.php delete mode 100644 owl-bot-staging/Build/v1/src/V1/Gapic/CloudBuildGapicClient.php delete mode 100644 owl-bot-staging/Build/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/Build/v1/src/V1/resources/cloud_build_client_config.json delete mode 100644 owl-bot-staging/Build/v1/src/V1/resources/cloud_build_descriptor_config.php delete mode 100644 owl-bot-staging/Build/v1/src/V1/resources/cloud_build_rest_client_config.php delete mode 100644 owl-bot-staging/Build/v1/tests/Unit/V1/CloudBuildClientTest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Cloudbuild.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Repositories.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/BatchCreateRepositoriesRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/BatchCreateRepositoriesResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Connection.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateConnectionRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateRepositoryRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteConnectionRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteRepositoryRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetConnectionRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetRepositoryRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubConfig.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubEnterpriseConfig.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState/Stage.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState_Stage.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListConnectionsRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListConnectionsResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesRequest.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesResponse.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OAuthCredential.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OperationMetadata.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Repository.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RepositoryManagerGrpcClient.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RunWorkflowCustomOperationMetadata.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ServiceDirectoryConfig.php delete mode 100644 owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/UpdateConnectionRequest.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/batch_create_repositories.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_connection.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_repository.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_connection.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_repository.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_token.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_write_token.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_connection.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_iam_policy.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_repository.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_connections.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_repositories.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/set_iam_policy.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/update_connection.php delete mode 100644 owl-bot-staging/Build/v2/src/V2/Gapic/RepositoryManagerGapicClient.php delete mode 100644 owl-bot-staging/Build/v2/src/V2/RepositoryManagerClient.php delete mode 100644 owl-bot-staging/Build/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/Build/v2/src/V2/resources/repository_manager_client_config.json delete mode 100644 owl-bot-staging/Build/v2/src/V2/resources/repository_manager_descriptor_config.php delete mode 100644 owl-bot-staging/Build/v2/src/V2/resources/repository_manager_rest_client_config.php delete mode 100644 owl-bot-staging/Build/v2/tests/Unit/V2/RepositoryManagerClientTest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateIssuanceConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateManager.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/FailureReason.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/State.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue/Reason.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/State.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/Scope.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/SelfManagedCertificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig/CertificateAuthorityServiceConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/KeyAlgorithm.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_CertificateAuthorityConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_CertificateAuthorityConfig_CertificateAuthorityServiceConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_KeyAlgorithm.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateManagerGrpcClient.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget/IpConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry/Matcher.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry_Matcher.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap_GclbTarget.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap_GclbTarget_IpConfig.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_AuthorizationAttemptInfo.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_AuthorizationAttemptInfo_FailureReason.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_AuthorizationAttemptInfo_State.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_ProvisioningIssue.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_ProvisioningIssue_Reason.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_ManagedCertificate_State.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_Scope.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate_SelfManagedCertificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateIssuanceConfigRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapEntryRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateDnsAuthorizationRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateIssuanceConfigRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapEntryRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteDnsAuthorizationRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization/DnsResourceRecord.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization_DnsResourceRecord.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateIssuanceConfigRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapEntryRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetDnsAuthorizationRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsResponse.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesResponse.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsResponse.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesResponse.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsResponse.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ServingState.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapEntryRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateDnsAuthorizationRequest.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map_entry.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_dns_authorization.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_dns_authorization.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map_entry.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_dns_authorization.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_location.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_map_entries.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_maps.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificates.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_dns_authorizations.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_locations.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map_entry.php delete mode 100644 owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_dns_authorization.php delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/CertificateManagerClient.php delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/Gapic/CertificateManagerGapicClient.php delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_client_config.json delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_descriptor_config.php delete mode 100644 owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_rest_client_config.php delete mode 100644 owl-bot-staging/CertificateManager/v1/tests/Unit/V1/CertificateManagerClientTest.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/GPBMetadata/Google/Cloud/Confidentialcomputing/V1/Service.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/Challenge.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/ConfidentialComputingGrpcClient.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/CreateChallengeRequest.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/GcpCredentials.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation/Quote.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation_Quote.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/VerifyAttestationRequest.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/VerifyAttestationResponse.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/create_challenge.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/get_location.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/list_locations.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/verify_attestation.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/ConfidentialComputingClient.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/Gapic/ConfidentialComputingGapicClient.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_client_config.json delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_descriptor_config.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_rest_client_config.php delete mode 100644 owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/ConfidentialComputingClientTest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/GPBMetadata/Google/Cloud/Datacatalog/Lineage/V1/Lineage.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesResponse.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateLineageEventRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateProcessRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateRunRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteLineageEventRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteProcessRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteRunRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EntityReference.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EventLink.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetLineageEventRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetProcessRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetRunRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageEvent.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageGrpcClient.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Link.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsResponse.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesResponse.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsResponse.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/State.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/Type.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata_State.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata_Type.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin/SourceType.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin_SourceType.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Process.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinkInfo.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinks.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run/State.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run_State.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/SearchLinksRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/SearchLinksResponse.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateProcessRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateRunRequest.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/batch_search_link_processes.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_lineage_event.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_process.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_run.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_lineage_event.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_process.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_run.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_lineage_event.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_process.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_run.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_lineage_events.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_processes.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_runs.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/search_links.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_process.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_run.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/Gapic/LineageGapicClient.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/LineageClient.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_client_config.json delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_descriptor_config.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_rest_client_config.php delete mode 100644 owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/LineageClientTest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/GPBMetadata/Google/Cloud/Datafusion/V1/Datafusion.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/AcceleratorType.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/State.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator_AcceleratorType.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator_State.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/CreateInstanceRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/CryptoKeyConfig.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DataFusionGrpcClient.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DeleteInstanceRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/GetInstanceRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/DisabledReason.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/State.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/Type.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_DisabledReason.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_State.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_Type.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListAvailableVersionsRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListAvailableVersionsResponse.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesResponse.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/NetworkConfig.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/RestartInstanceRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/UpdateInstanceRequest.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version/Type.php delete mode 100644 owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version_Type.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/create_instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/delete_instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/get_instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_available_versions.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_instances.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/restart_instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/update_instance.php delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/DataFusionClient.php delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/Gapic/DataFusionGapicClient.php delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_client_config.json delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_descriptor_config.php delete mode 100644 owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_rest_client_config.php delete mode 100644 owl-bot-staging/DataFusion/v1/tests/Unit/V1/DataFusionClientTest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Annotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/AnnotationSpecSet.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/DataLabelingService.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/DataPayloads.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Evaluation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/EvaluationJob.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/HumanAnnotationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Instruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Operations.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotatedDataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotatedDatasetMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Annotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationSentiment.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationSource.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationSpec.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationSpecSet.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationType.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/AnnotationValue.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Attempt.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/BigQuerySource.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/BoundingBoxEvaluationOptions.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/BoundingPoly.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/BoundingPolyConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ClassificationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ClassificationMetrics.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ConfusionMatrix.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ConfusionMatrix/ConfusionMatrixEntry.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ConfusionMatrix/Row.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ConfusionMatrix_ConfusionMatrixEntry.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ConfusionMatrix_Row.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CreateAnnotationSpecSetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CreateDatasetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CreateEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CreateInstructionMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CreateInstructionRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/CsvInstruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DataItem.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DataLabelingServiceGrpcClient.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DataType.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DeleteAnnotatedDatasetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DeleteAnnotationSpecSetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DeleteDatasetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DeleteEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/DeleteInstructionRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Evaluation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationJob.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationJob/State.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationJobAlertConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationJobConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationJob_State.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EvaluationMetrics.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/EventConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Example.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ExportDataOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ExportDataOperationResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ExportDataRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GcsDestination.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GcsFolderDestination.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GcsSource.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetAnnotatedDatasetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetAnnotationSpecSetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetDataItemRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetDatasetRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetEvaluationRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetExampleRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/GetInstructionRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/HumanAnnotationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImageBoundingPolyAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImageClassificationAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImageClassificationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImagePayload.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImagePolylineAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImageSegmentationAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImportDataOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImportDataOperationResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ImportDataRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/InputConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Instruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageBoundingBoxOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageBoundingPolyOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageClassificationOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageOrientedBoundingBoxOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImagePolylineOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageRequest/Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageRequest_Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelImageSegmentationOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelStats.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelTextClassificationOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelTextEntityExtractionOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelTextRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelTextRequest/Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelTextRequest_Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoClassificationOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoEventOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoObjectDetectionOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoObjectTrackingOperationMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoRequest/Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/LabelVideoRequest_Feature.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListAnnotatedDatasetsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListAnnotatedDatasetsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListAnnotationSpecSetsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListAnnotationSpecSetsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListDataItemsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListDataItemsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListDatasetsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListDatasetsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListEvaluationJobsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListEvaluationJobsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListExamplesRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListExamplesResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListInstructionsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ListInstructionsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/NormalizedBoundingPoly.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/NormalizedPolyline.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/NormalizedVertex.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ObjectDetectionConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ObjectDetectionMetrics.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ObjectTrackingConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ObjectTrackingFrame.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/OperatorMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/OutputConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PauseEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PdfInstruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Polyline.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PolylineConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PrCurve.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PrCurve/ConfidenceMetricsEntry.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/PrCurve_ConfidenceMetricsEntry.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/ResumeEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchEvaluationsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchEvaluationsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchExampleComparisonsRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchExampleComparisonsResponse.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchExampleComparisonsResponse/ExampleComparison.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SearchExampleComparisonsResponse_ExampleComparison.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SegmentationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SentimentConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/SequentialSegment.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/StringAggregationType.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextClassificationAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextClassificationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextEntityExtractionAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextEntityExtractionConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextMetadata.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TextPayload.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/TimeSegment.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/UpdateEvaluationJobRequest.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/Vertex.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoClassificationAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoClassificationConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoClassificationConfig/AnnotationSpecSetConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoClassificationConfig_AnnotationSpecSetConfig.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoEventAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoObjectTrackingAnnotation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoPayload.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/proto/src/Google/Cloud/DataLabeling/V1beta1/VideoThumbnail.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/create_annotation_spec_set.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/create_dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/create_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/create_instruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/delete_annotated_dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/delete_annotation_spec_set.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/delete_dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/delete_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/delete_instruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/export_data.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_annotated_dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_annotation_spec_set.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_data_item.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_dataset.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_evaluation.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_example.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/get_instruction.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/import_data.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/label_image.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/label_text.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/label_video.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_annotated_datasets.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_annotation_spec_sets.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_data_items.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_datasets.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_evaluation_jobs.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_examples.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/list_instructions.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/pause_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/resume_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/search_evaluations.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/search_example_comparisons.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/samples/V1beta1/DataLabelingServiceClient/update_evaluation_job.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/DataLabelingServiceClient.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/Gapic/DataLabelingServiceGapicClient.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/gapic_metadata.json delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/resources/data_labeling_service_client_config.json delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/resources/data_labeling_service_descriptor_config.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/resources/data_labeling_service_rest_client_config.php delete mode 100644 owl-bot-staging/DataLabeling/v1beta1/tests/Unit/V1beta1/DataLabelingServiceClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Environment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Jobs.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Messages.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Metrics.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Snapshots.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Streaming.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/GPBMetadata/Google/Dataflow/V1Beta3/Templates.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/AutoscalingAlgorithm.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/AutoscalingEvent.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/AutoscalingEvent/AutoscalingEventType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/AutoscalingEvent_AutoscalingEventType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/AutoscalingSettings.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/BigQueryIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/BigTableIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/CheckActiveJobsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/CheckActiveJobsResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ComputationTopology.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ContainerSpec.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/CreateJobFromTemplateRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/CreateJobRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/CustomSourceLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DataDiskAssignment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DatastoreIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DebugOptions.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DefaultPackageSet.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DeleteSnapshotRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DeleteSnapshotResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Disk.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DisplayData.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/DynamicTemplateLaunchParams.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Environment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageState.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary/ComponentSource.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary/ComponentTransform.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary/StageSource.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary_ComponentSource.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary_ComponentTransform.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionStageSummary_StageSource.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ExecutionState.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/FailedLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/FileIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/FlexResourceSchedulingGoal.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/FlexTemplateRuntimeEnvironment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/FlexTemplatesServiceGrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetJobExecutionDetailsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetJobMetricsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetJobRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetSnapshotRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetStageExecutionDetailsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateRequest/TemplateView.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateRequest_TemplateView.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateResponse/TemplateType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/GetTemplateResponse_TemplateType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/InvalidTemplateParameters.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/InvalidTemplateParameters/ParameterViolation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/InvalidTemplateParameters_ParameterViolation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Job.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobExecutionDetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobExecutionInfo.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobExecutionStageInfo.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobMessage.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobMessageImportance.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobMetadata.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobMetrics.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobState.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobView.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/JobsV1Beta3GrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/KeyRangeDataDiskAssignment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/KeyRangeLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/KindType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchFlexTemplateParameter.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchFlexTemplateRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchFlexTemplateResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchTemplateParameters.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchTemplateRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/LaunchTemplateResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobMessagesRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobMessagesResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobsRequest/Filter.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobsRequest_Filter.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListJobsResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListSnapshotsRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ListSnapshotsResponse.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/MessagesV1Beta3GrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/MetricStructuredName.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/MetricUpdate.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/MetricsV1Beta3GrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/MountedDataDisk.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Package.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ParameterMetadata.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ParameterType.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/PipelineDescription.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ProgressTimeseries.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ProgressTimeseries/Point.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ProgressTimeseries_Point.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/PubSubIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/PubsubLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/PubsubSnapshotMetadata.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/RuntimeEnvironment.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/RuntimeMetadata.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SDKInfo.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SDKInfo/Language.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SDKInfo_Language.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SdkHarnessContainerImage.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SdkVersion.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SdkVersion/SdkSupportStatus.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SdkVersion_SdkSupportStatus.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/ShuffleMode.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Snapshot.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SnapshotJobRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SnapshotState.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SnapshotsV1Beta3GrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/SpannerIODetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StageExecutionDetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StageSummary.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StateFamilyConfig.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/Step.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StreamLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StreamingApplianceSnapshotConfig.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StreamingComputationRanges.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StreamingSideInputLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StreamingStageLocation.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StructuredMessage.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StructuredMessage/Parameter.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/StructuredMessage_Parameter.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TaskRunnerSettings.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TeardownPolicy.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TemplateMetadata.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TemplatesServiceGrpcClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TopologyConfig.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/TransformSummary.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/UpdateJobRequest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/WorkItemDetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/WorkerDetails.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/WorkerIPAddressConfiguration.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/WorkerPool.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/proto/src/Google/Cloud/Dataflow/V1beta3/WorkerSettings.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/FlexTemplatesServiceClient/launch_flex_template.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/aggregated_list_jobs.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/check_active_jobs.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/create_job.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/get_job.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/list_jobs.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/snapshot_job.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/JobsV1Beta3Client/update_job.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/MessagesV1Beta3Client/list_job_messages.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/MetricsV1Beta3Client/get_job_execution_details.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/MetricsV1Beta3Client/get_job_metrics.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/MetricsV1Beta3Client/get_stage_execution_details.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/SnapshotsV1Beta3Client/delete_snapshot.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/SnapshotsV1Beta3Client/get_snapshot.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/SnapshotsV1Beta3Client/list_snapshots.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/TemplatesServiceClient/create_job_from_template.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/TemplatesServiceClient/get_template.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/samples/V1beta3/TemplatesServiceClient/launch_template.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/FlexTemplatesServiceClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/FlexTemplatesServiceGapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/JobsV1Beta3GapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/MessagesV1Beta3GapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/MetricsV1Beta3GapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/SnapshotsV1Beta3GapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Gapic/TemplatesServiceGapicClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/JobsV1Beta3Client.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/MessagesV1Beta3Client.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/MetricsV1Beta3Client.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/SnapshotsV1Beta3Client.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/TemplatesServiceClient.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/gapic_metadata.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/flex_templates_service_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/flex_templates_service_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/flex_templates_service_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/jobs_v1_beta3_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/jobs_v1_beta3_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/jobs_v1_beta3_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/messages_v1_beta3_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/messages_v1_beta3_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/messages_v1_beta3_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/metrics_v1_beta3_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/metrics_v1_beta3_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/metrics_v1_beta3_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/snapshots_v1_beta3_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/snapshots_v1_beta3_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/snapshots_v1_beta3_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/templates_service_client_config.json delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/templates_service_descriptor_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/src/V1beta3/resources/templates_service_rest_client_config.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/FlexTemplatesServiceClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/JobsV1Beta3ClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/MessagesV1Beta3ClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/MetricsV1Beta3ClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/SnapshotsV1Beta3ClientTest.php delete mode 100644 owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/TemplatesServiceClientTest.php diff --git a/ApiKeys/samples/V2/ApiKeysClient/create_key.php b/ApiKeys/samples/V2/ApiKeysClient/create_key.php index aab6931b3429..f3eaf59347bb 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/create_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/create_key.php @@ -25,7 +25,8 @@ // [START apikeys_v2_generated_ApiKeys_CreateKey_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\CreateKeyRequest; use Google\Cloud\ApiKeys\V2\Key; use Google\Rpc\Status; @@ -43,13 +44,16 @@ function create_key_sample(string $formattedParent): void // Create a client. $apiKeysClient = new ApiKeysClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $key = new Key(); + $request = (new CreateKeyRequest()) + ->setParent($formattedParent) + ->setKey($key); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $apiKeysClient->createKey($formattedParent, $key); + $response = $apiKeysClient->createKey($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/ApiKeys/samples/V2/ApiKeysClient/delete_key.php b/ApiKeys/samples/V2/ApiKeysClient/delete_key.php index 82da4a8766ac..ad85e4fa17de 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/delete_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/delete_key.php @@ -25,7 +25,8 @@ // [START apikeys_v2_generated_ApiKeys_DeleteKey_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\DeleteKeyRequest; use Google\Cloud\ApiKeys\V2\Key; use Google\Rpc\Status; @@ -44,10 +45,14 @@ function delete_key_sample(string $formattedName): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new DeleteKeyRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $apiKeysClient->deleteKey($formattedName); + $response = $apiKeysClient->deleteKey($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/ApiKeys/samples/V2/ApiKeysClient/get_key.php b/ApiKeys/samples/V2/ApiKeysClient/get_key.php index 5e4651e8c8ea..2233d3702980 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/get_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/get_key.php @@ -24,7 +24,8 @@ // [START apikeys_v2_generated_ApiKeys_GetKey_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\GetKeyRequest; use Google\Cloud\ApiKeys\V2\Key; /** @@ -42,10 +43,14 @@ function get_key_sample(string $formattedName): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new GetKeyRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Key $response */ - $response = $apiKeysClient->getKey($formattedName); + $response = $apiKeysClient->getKey($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApiKeys/samples/V2/ApiKeysClient/get_key_string.php b/ApiKeys/samples/V2/ApiKeysClient/get_key_string.php index 62dd7a442431..5d6c27306ee5 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/get_key_string.php +++ b/ApiKeys/samples/V2/ApiKeysClient/get_key_string.php @@ -24,7 +24,8 @@ // [START apikeys_v2_generated_ApiKeys_GetKeyString_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\GetKeyStringRequest; use Google\Cloud\ApiKeys\V2\GetKeyStringResponse; /** @@ -41,10 +42,14 @@ function get_key_string_sample(string $formattedName): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new GetKeyStringRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var GetKeyStringResponse $response */ - $response = $apiKeysClient->getKeyString($formattedName); + $response = $apiKeysClient->getKeyString($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApiKeys/samples/V2/ApiKeysClient/list_keys.php b/ApiKeys/samples/V2/ApiKeysClient/list_keys.php index cb2ede054b80..14792e60cea3 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/list_keys.php +++ b/ApiKeys/samples/V2/ApiKeysClient/list_keys.php @@ -25,8 +25,9 @@ // [START apikeys_v2_generated_ApiKeys_ListKeys_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; use Google\Cloud\ApiKeys\V2\Key; +use Google\Cloud\ApiKeys\V2\ListKeysRequest; /** * Lists the API keys owned by a project. The key string of the API key @@ -43,10 +44,14 @@ function list_keys_sample(string $formattedParent): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new ListKeysRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $apiKeysClient->listKeys($formattedParent); + $response = $apiKeysClient->listKeys($request); /** @var Key $element */ foreach ($response as $element) { diff --git a/ApiKeys/samples/V2/ApiKeysClient/lookup_key.php b/ApiKeys/samples/V2/ApiKeysClient/lookup_key.php index cc889c84a0d7..e530422fb16c 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/lookup_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/lookup_key.php @@ -24,7 +24,8 @@ // [START apikeys_v2_generated_ApiKeys_LookupKey_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\LookupKeyRequest; use Google\Cloud\ApiKeys\V2\LookupKeyResponse; /** @@ -41,10 +42,14 @@ function lookup_key_sample(string $keyString): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new LookupKeyRequest()) + ->setKeyString($keyString); + // Call the API and handle any network failures. try { /** @var LookupKeyResponse $response */ - $response = $apiKeysClient->lookupKey($keyString); + $response = $apiKeysClient->lookupKey($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApiKeys/samples/V2/ApiKeysClient/undelete_key.php b/ApiKeys/samples/V2/ApiKeysClient/undelete_key.php index ba80f216103d..5b463be37f61 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/undelete_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/undelete_key.php @@ -25,8 +25,9 @@ // [START apikeys_v2_generated_ApiKeys_UndeleteKey_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; use Google\Cloud\ApiKeys\V2\Key; +use Google\Cloud\ApiKeys\V2\UndeleteKeyRequest; use Google\Rpc\Status; /** @@ -43,10 +44,14 @@ function undelete_key_sample(string $formattedName): void // Create a client. $apiKeysClient = new ApiKeysClient(); + // Prepare the request message. + $request = (new UndeleteKeyRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $apiKeysClient->undeleteKey($formattedName); + $response = $apiKeysClient->undeleteKey($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/ApiKeys/samples/V2/ApiKeysClient/update_key.php b/ApiKeys/samples/V2/ApiKeysClient/update_key.php index a5824e522ae3..44c30c827b3b 100644 --- a/ApiKeys/samples/V2/ApiKeysClient/update_key.php +++ b/ApiKeys/samples/V2/ApiKeysClient/update_key.php @@ -25,8 +25,9 @@ // [START apikeys_v2_generated_ApiKeys_UpdateKey_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\ApiKeys\V2\ApiKeysClient; +use Google\Cloud\ApiKeys\V2\Client\ApiKeysClient; use Google\Cloud\ApiKeys\V2\Key; +use Google\Cloud\ApiKeys\V2\UpdateKeyRequest; use Google\Rpc\Status; /** @@ -47,13 +48,15 @@ function update_key_sample(): void // Create a client. $apiKeysClient = new ApiKeysClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $key = new Key(); + $request = (new UpdateKeyRequest()) + ->setKey($key); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $apiKeysClient->updateKey($key); + $response = $apiKeysClient->updateKey($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/Client/ApiKeysClient.php b/ApiKeys/src/V2/Client/ApiKeysClient.php similarity index 100% rename from owl-bot-staging/ApiKeys/v2/src/V2/Client/ApiKeysClient.php rename to ApiKeys/src/V2/Client/ApiKeysClient.php diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/Client/BaseClient/ApiKeysBaseClient.php b/ApiKeys/src/V2/Client/BaseClient/ApiKeysBaseClient.php similarity index 100% rename from owl-bot-staging/ApiKeys/v2/src/V2/Client/BaseClient/ApiKeysBaseClient.php rename to ApiKeys/src/V2/Client/BaseClient/ApiKeysBaseClient.php diff --git a/ApiKeys/src/V2/CreateKeyRequest.php b/ApiKeys/src/V2/CreateKeyRequest.php index 88b615ddb481..e0c6b3efebae 100644 --- a/ApiKeys/src/V2/CreateKeyRequest.php +++ b/ApiKeys/src/V2/CreateKeyRequest.php @@ -42,6 +42,34 @@ class CreateKeyRequest extends \Google\Protobuf\Internal\Message */ private $key_id = ''; + /** + * @param string $parent Required. The project in which the API key is created. Please see + * {@see ApiKeysClient::locationName()} for help formatting this field. + * @param \Google\Cloud\ApiKeys\V2\Key $key Required. The API key fields to set at creation time. + * You can configure only the `display_name`, `restrictions`, and + * `annotations` fields. + * @param string $keyId User specified key id (optional). If specified, it will become the final + * component of the key resource name. + * + * The id must be unique within the project, must conform with RFC-1034, + * is restricted to lower-cased letters, and has a maximum length of 63 + * characters. In another word, the id must match the regular + * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. + * + * The id must NOT be a UUID-like string. + * + * @return \Google\Cloud\ApiKeys\V2\CreateKeyRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApiKeys\V2\Key $key, string $keyId): self + { + return (new self()) + ->setParent($parent) + ->setKey($key) + ->setKeyId($keyId); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/DeleteKeyRequest.php b/ApiKeys/src/V2/DeleteKeyRequest.php index d4c5a8fec0c6..ab2d74394d00 100644 --- a/ApiKeys/src/V2/DeleteKeyRequest.php +++ b/ApiKeys/src/V2/DeleteKeyRequest.php @@ -29,6 +29,20 @@ class DeleteKeyRequest extends \Google\Protobuf\Internal\Message */ private $etag = ''; + /** + * @param string $name Required. The resource name of the API key to be deleted. Please see + * {@see ApiKeysClient::keyName()} for help formatting this field. + * + * @return \Google\Cloud\ApiKeys\V2\DeleteKeyRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/GetKeyRequest.php b/ApiKeys/src/V2/GetKeyRequest.php index 3e7224678964..e9d137c7deaa 100644 --- a/ApiKeys/src/V2/GetKeyRequest.php +++ b/ApiKeys/src/V2/GetKeyRequest.php @@ -22,6 +22,20 @@ class GetKeyRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the API key to get. Please see + * {@see ApiKeysClient::keyName()} for help formatting this field. + * + * @return \Google\Cloud\ApiKeys\V2\GetKeyRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/GetKeyStringRequest.php b/ApiKeys/src/V2/GetKeyStringRequest.php index 00f36e5e9a5e..9366e02c076f 100644 --- a/ApiKeys/src/V2/GetKeyStringRequest.php +++ b/ApiKeys/src/V2/GetKeyStringRequest.php @@ -22,6 +22,20 @@ class GetKeyStringRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the API key to be retrieved. Please see + * {@see ApiKeysClient::keyName()} for help formatting this field. + * + * @return \Google\Cloud\ApiKeys\V2\GetKeyStringRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/ListKeysRequest.php b/ApiKeys/src/V2/ListKeysRequest.php index d13e7640604a..7f78cb01a8d6 100644 --- a/ApiKeys/src/V2/ListKeysRequest.php +++ b/ApiKeys/src/V2/ListKeysRequest.php @@ -41,6 +41,20 @@ class ListKeysRequest extends \Google\Protobuf\Internal\Message */ private $show_deleted = false; + /** + * @param string $parent Required. Lists all API keys associated with this project. Please see + * {@see ApiKeysClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\ApiKeys\V2\ListKeysRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/UpdateKeyRequest.php b/ApiKeys/src/V2/UpdateKeyRequest.php index 5c0dfcf80b0a..c3bf1a08d73a 100644 --- a/ApiKeys/src/V2/UpdateKeyRequest.php +++ b/ApiKeys/src/V2/UpdateKeyRequest.php @@ -36,6 +36,29 @@ class UpdateKeyRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\ApiKeys\V2\Key $key Required. Set the `name` field to the resource name of the API key to be + * updated. You can update only the `display_name`, `restrictions`, and + * `annotations` fields. + * @param \Google\Protobuf\FieldMask $updateMask The field mask specifies which fields to be updated as part of this + * request. All other fields are ignored. + * Mutable fields are: `display_name`, `restrictions`, and `annotations`. + * If an update mask is not provided, the service treats it as an implied mask + * equivalent to all allowed fields that are set on the wire. If the field + * mask has a special value "*", the service treats it equivalent to replace + * all allowed mutable fields. + * + * @return \Google\Cloud\ApiKeys\V2\UpdateKeyRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApiKeys\V2\Key $key, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setKey($key) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/ApiKeys/src/V2/resources/api_keys_descriptor_config.php b/ApiKeys/src/V2/resources/api_keys_descriptor_config.php index c83e3ac1e3fc..cfdbad576236 100644 --- a/ApiKeys/src/V2/resources/api_keys_descriptor_config.php +++ b/ApiKeys/src/V2/resources/api_keys_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteKey' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UndeleteKey' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateKey' => [ 'longRunning' => [ @@ -42,6 +69,40 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'key.name', + 'fieldAccessors' => [ + 'getKey', + 'getName', + ], + ], + ], + ], + 'GetKey' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApiKeys\V2\Key', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetKeyString' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApiKeys\V2\GetKeyStringResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListKeys' => [ 'pageStreaming' => [ @@ -52,6 +113,24 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getKeys', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApiKeys\V2\ListKeysResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'LookupKey' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApiKeys\V2\LookupKeyResponse', + ], + 'templateMap' => [ + 'key' => 'projects/{project}/locations/{location}/keys/{key}', + 'location' => 'projects/{project}/locations/{location}', ], ], ], diff --git a/owl-bot-staging/ApiKeys/v2/tests/Unit/V2/Client/ApiKeysClientTest.php b/ApiKeys/tests/Unit/V2/Client/ApiKeysClientTest.php similarity index 100% rename from owl-bot-staging/ApiKeys/v2/tests/Unit/V2/Client/ApiKeysClientTest.php rename to ApiKeys/tests/Unit/V2/Client/ApiKeysClientTest.php diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/create_instance.php b/ApigeeRegistry/samples/V1/ProvisioningClient/create_instance.php index f81897ce4492..c8071bc30066 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/create_instance.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/create_instance.php @@ -25,9 +25,10 @@ // [START apigeeregistry_v1_generated_Provisioning_CreateInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\CreateInstanceRequest; use Google\Cloud\ApigeeRegistry\V1\Instance; use Google\Cloud\ApigeeRegistry\V1\Instance\Config; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; use Google\Rpc\Status; /** @@ -50,16 +51,20 @@ function create_instance_sample( // Create a client. $provisioningClient = new ProvisioningClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $instanceConfig = (new Config()) ->setCmekKeyName($instanceConfigCmekKeyName); $instance = (new Instance()) ->setConfig($instanceConfig); + $request = (new CreateInstanceRequest()) + ->setParent($formattedParent) + ->setInstanceId($instanceId) + ->setInstance($instance); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $provisioningClient->createInstance($formattedParent, $instanceId, $instance); + $response = $provisioningClient->createInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/delete_instance.php b/ApigeeRegistry/samples/V1/ProvisioningClient/delete_instance.php index e017de64da8f..83d8f152810f 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/delete_instance.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/delete_instance.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Provisioning_DeleteInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteInstanceRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_instance_sample(string $formattedName): void // Create a client. $provisioningClient = new ProvisioningClient(); + // Prepare the request message. + $request = (new DeleteInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $provisioningClient->deleteInstance($formattedName); + $response = $provisioningClient->deleteInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/get_iam_policy.php b/ApigeeRegistry/samples/V1/ProvisioningClient/get_iam_policy.php index b23007602a16..9f98a2db53c8 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/get_iam_policy.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Provisioning_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $provisioningClient = new ProvisioningClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $provisioningClient->getIamPolicy($resource); + $response = $provisioningClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/get_instance.php b/ApigeeRegistry/samples/V1/ProvisioningClient/get_instance.php index e054657d85f3..f348c51f6672 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/get_instance.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/get_instance.php @@ -24,8 +24,9 @@ // [START apigeeregistry_v1_generated_Provisioning_GetInstance_sync] use Google\ApiCore\ApiException; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\GetInstanceRequest; use Google\Cloud\ApigeeRegistry\V1\Instance; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; /** * Gets details of a single Instance. @@ -39,10 +40,14 @@ function get_instance_sample(string $formattedName): void // Create a client. $provisioningClient = new ProvisioningClient(); + // Prepare the request message. + $request = (new GetInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Instance $response */ - $response = $provisioningClient->getInstance($formattedName); + $response = $provisioningClient->getInstance($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/get_location.php b/ApigeeRegistry/samples/V1/ProvisioningClient/get_location.php index ea4c815734fc..ff091b74ceca 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/get_location.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/get_location.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Provisioning_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $provisioningClient = new ProvisioningClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $provisioningClient->getLocation(); + $response = $provisioningClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/list_locations.php b/ApigeeRegistry/samples/V1/ProvisioningClient/list_locations.php index d3a28b9002f7..265b2a0395e8 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/list_locations.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/list_locations.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Provisioning_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $provisioningClient = new ProvisioningClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $provisioningClient->listLocations(); + $response = $provisioningClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/set_iam_policy.php b/ApigeeRegistry/samples/V1/ProvisioningClient/set_iam_policy.php index 008fd43ac804..ac628927c190 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/set_iam_policy.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START apigeeregistry_v1_generated_Provisioning_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $provisioningClient = new ProvisioningClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $provisioningClient->setIamPolicy($resource, $policy); + $response = $provisioningClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/ProvisioningClient/test_iam_permissions.php b/ApigeeRegistry/samples/V1/ProvisioningClient/test_iam_permissions.php index 2685d440ea80..f1e009ee4624 100644 --- a/ApigeeRegistry/samples/V1/ProvisioningClient/test_iam_permissions.php +++ b/ApigeeRegistry/samples/V1/ProvisioningClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Provisioning_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\ProvisioningClient; +use Google\Cloud\ApigeeRegistry\V1\Client\ProvisioningClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $provisioningClient = new ProvisioningClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $provisioningClient->testIamPermissions($resource, $permissions); + $response = $provisioningClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/create_api.php b/ApigeeRegistry/samples/V1/RegistryClient/create_api.php index a7255959f02e..3b2d2e9fc578 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/create_api.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/create_api.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_CreateApi_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Api; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\CreateApiRequest; /** * Creates a specified API. @@ -46,13 +47,17 @@ function create_api_sample(string $formattedParent, string $apiId): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $api = new Api(); + $request = (new CreateApiRequest()) + ->setParent($formattedParent) + ->setApi($api) + ->setApiId($apiId); // Call the API and handle any network failures. try { /** @var Api $response */ - $response = $registryClient->createApi($formattedParent, $api, $apiId); + $response = $registryClient->createApi($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/create_api_deployment.php b/ApigeeRegistry/samples/V1/RegistryClient/create_api_deployment.php index cb04fe335470..6d3b4f3bbd50 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/create_api_deployment.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/create_api_deployment.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_CreateApiDeployment_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\CreateApiDeploymentRequest; /** * Creates a specified deployment. @@ -46,17 +47,17 @@ function create_api_deployment_sample(string $formattedParent, string $apiDeploy // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiDeployment = new ApiDeployment(); + $request = (new CreateApiDeploymentRequest()) + ->setParent($formattedParent) + ->setApiDeployment($apiDeployment) + ->setApiDeploymentId($apiDeploymentId); // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->createApiDeployment( - $formattedParent, - $apiDeployment, - $apiDeploymentId - ); + $response = $registryClient->createApiDeployment($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/create_api_spec.php b/ApigeeRegistry/samples/V1/RegistryClient/create_api_spec.php index eee128c48bb1..7bfefa5933f9 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/create_api_spec.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/create_api_spec.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_CreateApiSpec_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\CreateApiSpecRequest; /** * Creates a specified spec. @@ -46,13 +47,17 @@ function create_api_spec_sample(string $formattedParent, string $apiSpecId): voi // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiSpec = new ApiSpec(); + $request = (new CreateApiSpecRequest()) + ->setParent($formattedParent) + ->setApiSpec($apiSpec) + ->setApiSpecId($apiSpecId); // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->createApiSpec($formattedParent, $apiSpec, $apiSpecId); + $response = $registryClient->createApiSpec($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/create_api_version.php b/ApigeeRegistry/samples/V1/RegistryClient/create_api_version.php index 6fefc0d06638..fd7ad3243b46 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/create_api_version.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/create_api_version.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_CreateApiVersion_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiVersion; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\CreateApiVersionRequest; /** * Creates a specified version. @@ -46,13 +47,17 @@ function create_api_version_sample(string $formattedParent, string $apiVersionId // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiVersion = new ApiVersion(); + $request = (new CreateApiVersionRequest()) + ->setParent($formattedParent) + ->setApiVersion($apiVersion) + ->setApiVersionId($apiVersionId); // Call the API and handle any network failures. try { /** @var ApiVersion $response */ - $response = $registryClient->createApiVersion($formattedParent, $apiVersion, $apiVersionId); + $response = $registryClient->createApiVersion($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/create_artifact.php b/ApigeeRegistry/samples/V1/RegistryClient/create_artifact.php index 07cf722af20a..4cdd3249c8e2 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/create_artifact.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/create_artifact.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_CreateArtifact_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Artifact; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\CreateArtifactRequest; /** * Creates a specified artifact. @@ -46,13 +47,17 @@ function create_artifact_sample(string $formattedParent, string $artifactId): vo // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $artifact = new Artifact(); + $request = (new CreateArtifactRequest()) + ->setParent($formattedParent) + ->setArtifact($artifact) + ->setArtifactId($artifactId); // Call the API and handle any network failures. try { /** @var Artifact $response */ - $response = $registryClient->createArtifact($formattedParent, $artifact, $artifactId); + $response = $registryClient->createArtifact($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api.php index 974259d4abe9..fdc789fd6446 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApi_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiRequest; /** * Removes a specified API and all of the resources that it @@ -39,9 +40,13 @@ function delete_api_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $registryClient->deleteApi($formattedName); + $registryClient->deleteApi($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment.php index 6d8c7646eff8..2a9c94beecd5 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApiDeployment_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRequest; /** * Removes a specified deployment, all revisions, and all @@ -39,9 +40,13 @@ function delete_api_deployment_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiDeploymentRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $registryClient->deleteApiDeployment($formattedName); + $registryClient->deleteApiDeployment($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment_revision.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment_revision.php index 68af98ea1b6e..0ae70a39cbd9 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment_revision.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_deployment_revision.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApiDeploymentRevision_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRevisionRequest; /** * Deletes a revision of a deployment. @@ -42,10 +43,14 @@ function delete_api_deployment_revision_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiDeploymentRevisionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->deleteApiDeploymentRevision($formattedName); + $response = $registryClient->deleteApiDeploymentRevision($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec.php index f41aa726c5bd..252705f0d108 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApiSpec_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRequest; /** * Removes a specified spec, all revisions, and all child @@ -39,9 +40,13 @@ function delete_api_spec_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiSpecRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $registryClient->deleteApiSpec($formattedName); + $registryClient->deleteApiSpec($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec_revision.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec_revision.php index fe91ce08a23d..e735f380b23d 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec_revision.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_spec_revision.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApiSpecRevision_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRevisionRequest; /** * Deletes a revision of a spec. @@ -42,10 +43,14 @@ function delete_api_spec_revision_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiSpecRevisionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->deleteApiSpecRevision($formattedName); + $response = $registryClient->deleteApiSpecRevision($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_version.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_version.php index d8f74d06e84d..a6653b4248a4 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_api_version.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_api_version.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteApiVersion_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteApiVersionRequest; /** * Removes a specified version and all of the resources that @@ -39,9 +40,13 @@ function delete_api_version_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteApiVersionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $registryClient->deleteApiVersion($formattedName); + $registryClient->deleteApiVersion($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/delete_artifact.php b/ApigeeRegistry/samples/V1/RegistryClient/delete_artifact.php index c6552e7e93b4..b8ba60bd5c19 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/delete_artifact.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/delete_artifact.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_DeleteArtifact_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\DeleteArtifactRequest; /** * Removes a specified artifact. @@ -38,9 +39,13 @@ function delete_artifact_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new DeleteArtifactRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $registryClient->deleteArtifact($formattedName); + $registryClient->deleteArtifact($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_api.php b/ApigeeRegistry/samples/V1/RegistryClient/get_api.php index 16c712f335ba..10c0f0a9993b 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_api.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_api.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetApi_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Api; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetApiRequest; /** * Returns a specified API. @@ -39,10 +40,14 @@ function get_api_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetApiRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Api $response */ - $response = $registryClient->getApi($formattedName); + $response = $registryClient->getApi($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_api_deployment.php b/ApigeeRegistry/samples/V1/RegistryClient/get_api_deployment.php index 2b0331c1df05..6228ec1a7197 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_api_deployment.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_api_deployment.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetApiDeployment_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetApiDeploymentRequest; /** * Returns a specified deployment. @@ -39,10 +40,14 @@ function get_api_deployment_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetApiDeploymentRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->getApiDeployment($formattedName); + $response = $registryClient->getApiDeployment($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec.php b/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec.php index 079f8a866f3c..aab3c43fff8e 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetApiSpec_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetApiSpecRequest; /** * Returns a specified spec. @@ -39,10 +40,14 @@ function get_api_spec_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetApiSpecRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->getApiSpec($formattedName); + $response = $registryClient->getApiSpec($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec_contents.php b/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec_contents.php index 9c1775b0cbb9..c0e3ed038a9b 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec_contents.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_api_spec_contents.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetApiSpecContents_sync] use Google\ApiCore\ApiException; use Google\Api\HttpBody; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetApiSpecContentsRequest; /** * Returns the contents of a specified spec. @@ -42,10 +43,14 @@ function get_api_spec_contents_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetApiSpecContentsRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var HttpBody $response */ - $response = $registryClient->getApiSpecContents($formattedName); + $response = $registryClient->getApiSpecContents($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_api_version.php b/ApigeeRegistry/samples/V1/RegistryClient/get_api_version.php index f6ba7eee7c4d..091ede9c6db4 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_api_version.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_api_version.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetApiVersion_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiVersion; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetApiVersionRequest; /** * Returns a specified version. @@ -39,10 +40,14 @@ function get_api_version_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetApiVersionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ApiVersion $response */ - $response = $registryClient->getApiVersion($formattedName); + $response = $registryClient->getApiVersion($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_artifact.php b/ApigeeRegistry/samples/V1/RegistryClient/get_artifact.php index 459faac8b632..f702a37cf5a6 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_artifact.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_artifact.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetArtifact_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Artifact; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetArtifactRequest; /** * Returns a specified artifact. @@ -39,10 +40,14 @@ function get_artifact_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetArtifactRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Artifact $response */ - $response = $registryClient->getArtifact($formattedName); + $response = $registryClient->getArtifact($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_artifact_contents.php b/ApigeeRegistry/samples/V1/RegistryClient/get_artifact_contents.php index 7def877efa7d..e11ff2473a3f 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_artifact_contents.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_artifact_contents.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_GetArtifactContents_sync] use Google\ApiCore\ApiException; use Google\Api\HttpBody; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\GetArtifactContentsRequest; /** * Returns the contents of a specified artifact. @@ -42,10 +43,14 @@ function get_artifact_contents_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetArtifactContentsRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var HttpBody $response */ - $response = $registryClient->getArtifactContents($formattedName); + $response = $registryClient->getArtifactContents($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_iam_policy.php b/ApigeeRegistry/samples/V1/RegistryClient/get_iam_policy.php index b4db8d7931b1..b8d2149456b3 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_iam_policy.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $registryClient->getIamPolicy($resource); + $response = $registryClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/get_location.php b/ApigeeRegistry/samples/V1/RegistryClient/get_location.php index df19f971ae58..82a8e28a76a9 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/get_location.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/get_location.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $registryClient->getLocation(); + $response = $registryClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployment_revisions.php b/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployment_revisions.php index 71ec8ef06934..3a68e3f09764 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployment_revisions.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployment_revisions.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsRequest; /** * Lists all revisions of a deployment. @@ -40,10 +41,14 @@ function list_api_deployment_revisions_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApiDeploymentRevisionsRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApiDeploymentRevisions($formattedName); + $response = $registryClient->listApiDeploymentRevisions($request); /** @var ApiDeployment $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployments.php b/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployments.php index e92c589f4293..05e87dc2fe64 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployments.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_api_deployments.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsRequest; /** * Returns matching deployments. @@ -40,10 +41,14 @@ function list_api_deployments_sample(string $formattedParent): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApiDeploymentsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApiDeployments($formattedParent); + $response = $registryClient->listApiDeployments($request); /** @var ApiDeployment $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_api_spec_revisions.php b/ApigeeRegistry/samples/V1/RegistryClient/list_api_spec_revisions.php index bcaca72bf75b..b5a37e1f2295 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_api_spec_revisions.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_api_spec_revisions.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsRequest; /** * Lists all revisions of a spec. @@ -40,10 +41,14 @@ function list_api_spec_revisions_sample(string $formattedName): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApiSpecRevisionsRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApiSpecRevisions($formattedName); + $response = $registryClient->listApiSpecRevisions($request); /** @var ApiSpec $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_api_specs.php b/ApigeeRegistry/samples/V1/RegistryClient/list_api_specs.php index 91cfd4afc19c..be7c7d254614 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_api_specs.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_api_specs.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApiSpecsRequest; /** * Returns matching specs. @@ -40,10 +41,14 @@ function list_api_specs_sample(string $formattedParent): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApiSpecsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApiSpecs($formattedParent); + $response = $registryClient->listApiSpecs($request); /** @var ApiSpec $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_api_versions.php b/ApigeeRegistry/samples/V1/RegistryClient/list_api_versions.php index 19ff0212ff32..349c5bf2334e 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_api_versions.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_api_versions.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\ApiVersion; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApiVersionsRequest; /** * Returns matching versions. @@ -40,10 +41,14 @@ function list_api_versions_sample(string $formattedParent): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApiVersionsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApiVersions($formattedParent); + $response = $registryClient->listApiVersions($request); /** @var ApiVersion $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_apis.php b/ApigeeRegistry/samples/V1/RegistryClient/list_apis.php index 005b7e40e45f..32cde7d46edc 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_apis.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_apis.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\Api; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListApisRequest; /** * Returns matching APIs. @@ -40,10 +41,14 @@ function list_apis_sample(string $formattedParent): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListApisRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listApis($formattedParent); + $response = $registryClient->listApis($request); /** @var Api $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_artifacts.php b/ApigeeRegistry/samples/V1/RegistryClient/list_artifacts.php index 6870e42adb6b..befd0b55a657 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_artifacts.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_artifacts.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\ApigeeRegistry\V1\Artifact; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ListArtifactsRequest; /** * Returns matching artifacts. @@ -40,10 +41,14 @@ function list_artifacts_sample(string $formattedParent): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new ListArtifactsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listArtifacts($formattedParent); + $response = $registryClient->listArtifacts($request); /** @var Artifact $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/list_locations.php b/ApigeeRegistry/samples/V1/RegistryClient/list_locations.php index bfc62eba3061..d9b080aeaeb6 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/list_locations.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/list_locations.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $registryClient->listLocations(); + $response = $registryClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/ApigeeRegistry/samples/V1/RegistryClient/replace_artifact.php b/ApigeeRegistry/samples/V1/RegistryClient/replace_artifact.php index 1521d8d47345..4bde9aaf9fc5 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/replace_artifact.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/replace_artifact.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_ReplaceArtifact_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Artifact; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\ReplaceArtifactRequest; /** * Used to replace a specified artifact. @@ -41,13 +42,15 @@ function replace_artifact_sample(): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $artifact = new Artifact(); + $request = (new ReplaceArtifactRequest()) + ->setArtifact($artifact); // Call the API and handle any network failures. try { /** @var Artifact $response */ - $response = $registryClient->replaceArtifact($artifact); + $response = $registryClient->replaceArtifact($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_deployment.php b/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_deployment.php index 54cb67da61ef..866b0bd4ac85 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_deployment.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_deployment.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_RollbackApiDeployment_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\RollbackApiDeploymentRequest; /** * Sets the current revision to a specified prior @@ -43,10 +44,15 @@ function rollback_api_deployment_sample(string $formattedName, string $revisionI // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new RollbackApiDeploymentRequest()) + ->setName($formattedName) + ->setRevisionId($revisionId); + // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->rollbackApiDeployment($formattedName, $revisionId); + $response = $registryClient->rollbackApiDeployment($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_spec.php b/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_spec.php index b3cdd251f793..f2fdee566df4 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_spec.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/rollback_api_spec.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_RollbackApiSpec_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\RollbackApiSpecRequest; /** * Sets the current revision to a specified prior revision. @@ -43,10 +44,15 @@ function rollback_api_spec_sample(string $formattedName, string $revisionId): vo // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new RollbackApiSpecRequest()) + ->setName($formattedName) + ->setRevisionId($revisionId); + // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->rollbackApiSpec($formattedName, $revisionId); + $response = $registryClient->rollbackApiSpec($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/set_iam_policy.php b/ApigeeRegistry/samples/V1/RegistryClient/set_iam_policy.php index ee1ccc46e5c1..b6cbbaf0d2ec 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/set_iam_policy.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START apigeeregistry_v1_generated_Registry_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $registryClient->setIamPolicy($resource, $policy); + $response = $registryClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/tag_api_deployment_revision.php b/ApigeeRegistry/samples/V1/RegistryClient/tag_api_deployment_revision.php index faaaa935ce66..3c1b18b001c0 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/tag_api_deployment_revision.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/tag_api_deployment_revision.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_TagApiDeploymentRevision_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\TagApiDeploymentRevisionRequest; /** * Adds a tag to a specified revision of a @@ -41,10 +42,15 @@ function tag_api_deployment_revision_sample(string $formattedName, string $tag): // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new TagApiDeploymentRevisionRequest()) + ->setName($formattedName) + ->setTag($tag); + // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->tagApiDeploymentRevision($formattedName, $tag); + $response = $registryClient->tagApiDeploymentRevision($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/tag_api_spec_revision.php b/ApigeeRegistry/samples/V1/RegistryClient/tag_api_spec_revision.php index 228dcf468aac..6a382a50996d 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/tag_api_spec_revision.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/tag_api_spec_revision.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_TagApiSpecRevision_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\TagApiSpecRevisionRequest; /** * Adds a tag to a specified revision of a spec. @@ -40,10 +41,15 @@ function tag_api_spec_revision_sample(string $formattedName, string $tag): void // Create a client. $registryClient = new RegistryClient(); + // Prepare the request message. + $request = (new TagApiSpecRevisionRequest()) + ->setName($formattedName) + ->setTag($tag); + // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->tagApiSpecRevision($formattedName, $tag); + $response = $registryClient->tagApiSpecRevision($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/test_iam_permissions.php b/ApigeeRegistry/samples/V1/RegistryClient/test_iam_permissions.php index bb595c569764..4f721072c47a 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/test_iam_permissions.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START apigeeregistry_v1_generated_Registry_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $registryClient->testIamPermissions($resource, $permissions); + $response = $registryClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/update_api.php b/ApigeeRegistry/samples/V1/RegistryClient/update_api.php index 65b1eea75543..be70d577cb3f 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/update_api.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/update_api.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_UpdateApi_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\Api; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\UpdateApiRequest; /** * Used to modify a specified API. @@ -41,13 +42,15 @@ function update_api_sample(): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $api = new Api(); + $request = (new UpdateApiRequest()) + ->setApi($api); // Call the API and handle any network failures. try { /** @var Api $response */ - $response = $registryClient->updateApi($api); + $response = $registryClient->updateApi($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/update_api_deployment.php b/ApigeeRegistry/samples/V1/RegistryClient/update_api_deployment.php index 21a6915d87ac..6de2e8c8f56a 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/update_api_deployment.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/update_api_deployment.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_UpdateApiDeployment_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiDeployment; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\UpdateApiDeploymentRequest; /** * Used to modify a specified deployment. @@ -41,13 +42,15 @@ function update_api_deployment_sample(): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiDeployment = new ApiDeployment(); + $request = (new UpdateApiDeploymentRequest()) + ->setApiDeployment($apiDeployment); // Call the API and handle any network failures. try { /** @var ApiDeployment $response */ - $response = $registryClient->updateApiDeployment($apiDeployment); + $response = $registryClient->updateApiDeployment($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/update_api_spec.php b/ApigeeRegistry/samples/V1/RegistryClient/update_api_spec.php index a106f9e7d909..8a04c3990d4a 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/update_api_spec.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/update_api_spec.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_UpdateApiSpec_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiSpec; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\UpdateApiSpecRequest; /** * Used to modify a specified spec. @@ -41,13 +42,15 @@ function update_api_spec_sample(): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiSpec = new ApiSpec(); + $request = (new UpdateApiSpecRequest()) + ->setApiSpec($apiSpec); // Call the API and handle any network failures. try { /** @var ApiSpec $response */ - $response = $registryClient->updateApiSpec($apiSpec); + $response = $registryClient->updateApiSpec($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ApigeeRegistry/samples/V1/RegistryClient/update_api_version.php b/ApigeeRegistry/samples/V1/RegistryClient/update_api_version.php index 6daafdd86e50..a44567378ec6 100644 --- a/ApigeeRegistry/samples/V1/RegistryClient/update_api_version.php +++ b/ApigeeRegistry/samples/V1/RegistryClient/update_api_version.php @@ -25,7 +25,8 @@ // [START apigeeregistry_v1_generated_Registry_UpdateApiVersion_sync] use Google\ApiCore\ApiException; use Google\Cloud\ApigeeRegistry\V1\ApiVersion; -use Google\Cloud\ApigeeRegistry\V1\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\Client\RegistryClient; +use Google\Cloud\ApigeeRegistry\V1\UpdateApiVersionRequest; /** * Used to modify a specified version. @@ -41,13 +42,15 @@ function update_api_version_sample(): void // Create a client. $registryClient = new RegistryClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $apiVersion = new ApiVersion(); + $request = (new UpdateApiVersionRequest()) + ->setApiVersion($apiVersion); // Call the API and handle any network failures. try { /** @var ApiVersion $response */ - $response = $registryClient->updateApiVersion($apiVersion); + $response = $registryClient->updateApiVersion($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/BaseClient/ProvisioningBaseClient.php b/ApigeeRegistry/src/V1/Client/BaseClient/ProvisioningBaseClient.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/BaseClient/ProvisioningBaseClient.php rename to ApigeeRegistry/src/V1/Client/BaseClient/ProvisioningBaseClient.php diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/BaseClient/RegistryBaseClient.php b/ApigeeRegistry/src/V1/Client/BaseClient/RegistryBaseClient.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/BaseClient/RegistryBaseClient.php rename to ApigeeRegistry/src/V1/Client/BaseClient/RegistryBaseClient.php diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/ProvisioningClient.php b/ApigeeRegistry/src/V1/Client/ProvisioningClient.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/ProvisioningClient.php rename to ApigeeRegistry/src/V1/Client/ProvisioningClient.php diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/RegistryClient.php b/ApigeeRegistry/src/V1/Client/RegistryClient.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/src/V1/Client/RegistryClient.php rename to ApigeeRegistry/src/V1/Client/RegistryClient.php diff --git a/ApigeeRegistry/src/V1/CreateApiDeploymentRequest.php b/ApigeeRegistry/src/V1/CreateApiDeploymentRequest.php index 7ba51382ffd6..86383c1ea5d5 100644 --- a/ApigeeRegistry/src/V1/CreateApiDeploymentRequest.php +++ b/ApigeeRegistry/src/V1/CreateApiDeploymentRequest.php @@ -39,6 +39,31 @@ class CreateApiDeploymentRequest extends \Google\Protobuf\Internal\Message */ private $api_deployment_id = ''; + /** + * @param string $parent Required. The parent, which owns this collection of deployments. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment Required. The deployment to create. + * @param string $apiDeploymentId Required. The ID to use for the deployment, which will become the final component of + * the deployment's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Following AIP-162, IDs must not have the form of a UUID. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiDeploymentRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment, string $apiDeploymentId): self + { + return (new self()) + ->setParent($parent) + ->setApiDeployment($apiDeployment) + ->setApiDeploymentId($apiDeploymentId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/CreateApiRequest.php b/ApigeeRegistry/src/V1/CreateApiRequest.php index 34aa4078f26d..7ae6f6d728f0 100644 --- a/ApigeeRegistry/src/V1/CreateApiRequest.php +++ b/ApigeeRegistry/src/V1/CreateApiRequest.php @@ -39,6 +39,31 @@ class CreateApiRequest extends \Google\Protobuf\Internal\Message */ private $api_id = ''; + /** + * @param string $parent Required. The parent, which owns this collection of APIs. + * Format: `projects/*/locations/*` + * Please see {@see RegistryClient::locationName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\Api $api Required. The API to create. + * @param string $apiId Required. The ID to use for the API, which will become the final component of + * the API's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Following AIP-162, IDs must not have the form of a UUID. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Api $api, string $apiId): self + { + return (new self()) + ->setParent($parent) + ->setApi($api) + ->setApiId($apiId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/CreateApiSpecRequest.php b/ApigeeRegistry/src/V1/CreateApiSpecRequest.php index cab89587448c..d8c7805110ff 100644 --- a/ApigeeRegistry/src/V1/CreateApiSpecRequest.php +++ b/ApigeeRegistry/src/V1/CreateApiSpecRequest.php @@ -39,6 +39,31 @@ class CreateApiSpecRequest extends \Google\Protobuf\Internal\Message */ private $api_spec_id = ''; + /** + * @param string $parent Required. The parent, which owns this collection of specs. + * Format: `projects/*/locations/*/apis/*/versions/*` + * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec Required. The spec to create. + * @param string $apiSpecId Required. The ID to use for the spec, which will become the final component of + * the spec's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Following AIP-162, IDs must not have the form of a UUID. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiSpecRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec, string $apiSpecId): self + { + return (new self()) + ->setParent($parent) + ->setApiSpec($apiSpec) + ->setApiSpecId($apiSpecId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/CreateApiVersionRequest.php b/ApigeeRegistry/src/V1/CreateApiVersionRequest.php index b4253766319f..7deff8dea680 100644 --- a/ApigeeRegistry/src/V1/CreateApiVersionRequest.php +++ b/ApigeeRegistry/src/V1/CreateApiVersionRequest.php @@ -39,6 +39,31 @@ class CreateApiVersionRequest extends \Google\Protobuf\Internal\Message */ private $api_version_id = ''; + /** + * @param string $parent Required. The parent, which owns this collection of versions. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion Required. The version to create. + * @param string $apiVersionId Required. The ID to use for the version, which will become the final component of + * the version's resource name. + * + * This value should be 1-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Following AIP-162, IDs must not have the form of a UUID. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiVersionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion, string $apiVersionId): self + { + return (new self()) + ->setParent($parent) + ->setApiVersion($apiVersion) + ->setApiVersionId($apiVersionId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/CreateArtifactRequest.php b/ApigeeRegistry/src/V1/CreateArtifactRequest.php index 8c83a63f7f0d..57372d98b2c6 100644 --- a/ApigeeRegistry/src/V1/CreateArtifactRequest.php +++ b/ApigeeRegistry/src/V1/CreateArtifactRequest.php @@ -39,6 +39,31 @@ class CreateArtifactRequest extends \Google\Protobuf\Internal\Message */ private $artifact_id = ''; + /** + * @param string $parent Required. The parent, which owns this collection of artifacts. + * Format: `{parent}` + * Please see {@see RegistryClient::locationName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact Required. The artifact to create. + * @param string $artifactId Required. The ID to use for the artifact, which will become the final component of + * the artifact's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Following AIP-162, IDs must not have the form of a UUID. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateArtifactRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact, string $artifactId): self + { + return (new self()) + ->setParent($parent) + ->setArtifact($artifact) + ->setArtifactId($artifactId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/CreateInstanceRequest.php b/ApigeeRegistry/src/V1/CreateInstanceRequest.php index 0ebc4cb3372b..e095425853a6 100644 --- a/ApigeeRegistry/src/V1/CreateInstanceRequest.php +++ b/ApigeeRegistry/src/V1/CreateInstanceRequest.php @@ -35,6 +35,25 @@ class CreateInstanceRequest extends \Google\Protobuf\Internal\Message */ private $instance = null; + /** + * @param string $parent Required. Parent resource of the Instance, of the form: `projects/*/locations/*` + * Please see {@see ProvisioningClient::locationName()} for help formatting this field. + * @param \Google\Cloud\ApigeeRegistry\V1\Instance $instance Required. The Instance. + * @param string $instanceId Required. Identifier to assign to the Instance. Must be unique within scope of the + * parent resource. + * + * @return \Google\Cloud\ApigeeRegistry\V1\CreateInstanceRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Instance $instance, string $instanceId): self + { + return (new self()) + ->setParent($parent) + ->setInstance($instance) + ->setInstanceId($instanceId); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiDeploymentRequest.php b/ApigeeRegistry/src/V1/DeleteApiDeploymentRequest.php index ebb040f9121a..be3d27470300 100644 --- a/ApigeeRegistry/src/V1/DeleteApiDeploymentRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiDeploymentRequest.php @@ -30,6 +30,21 @@ class DeleteApiDeploymentRequest extends \Google\Protobuf\Internal\Message */ private $force = false; + /** + * @param string $name Required. The name of the deployment to delete. + * Format: `projects/*/locations/*/apis/*/deployments/*` + * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiDeploymentRevisionRequest.php b/ApigeeRegistry/src/V1/DeleteApiDeploymentRevisionRequest.php index c3fa13e7611b..197567f7b17c 100644 --- a/ApigeeRegistry/src/V1/DeleteApiDeploymentRevisionRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiDeploymentRevisionRequest.php @@ -25,6 +25,24 @@ class DeleteApiDeploymentRevisionRequest extends \Google\Protobuf\Internal\Messa */ private $name = ''; + /** + * @param string $name Required. The name of the deployment revision to be deleted, + * with a revision ID explicitly included. + * + * Example: + * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` + * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRevisionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiRequest.php b/ApigeeRegistry/src/V1/DeleteApiRequest.php index 65ff1d99bc67..fccfa8ab6a1a 100644 --- a/ApigeeRegistry/src/V1/DeleteApiRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiRequest.php @@ -30,6 +30,21 @@ class DeleteApiRequest extends \Google\Protobuf\Internal\Message */ private $force = false; + /** + * @param string $name Required. The name of the API to delete. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiSpecRequest.php b/ApigeeRegistry/src/V1/DeleteApiSpecRequest.php index 92a0d83f8ffd..cb88e6a266f7 100644 --- a/ApigeeRegistry/src/V1/DeleteApiSpecRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiSpecRequest.php @@ -30,6 +30,21 @@ class DeleteApiSpecRequest extends \Google\Protobuf\Internal\Message */ private $force = false; + /** + * @param string $name Required. The name of the spec to delete. + * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` + * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiSpecRevisionRequest.php b/ApigeeRegistry/src/V1/DeleteApiSpecRevisionRequest.php index 0e0a87a5287c..adba6faae0fe 100644 --- a/ApigeeRegistry/src/V1/DeleteApiSpecRevisionRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiSpecRevisionRequest.php @@ -25,6 +25,24 @@ class DeleteApiSpecRevisionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the spec revision to be deleted, + * with a revision ID explicitly included. + * + * Example: + * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` + * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRevisionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteApiVersionRequest.php b/ApigeeRegistry/src/V1/DeleteApiVersionRequest.php index a217ebd1d9de..a87667a58a66 100644 --- a/ApigeeRegistry/src/V1/DeleteApiVersionRequest.php +++ b/ApigeeRegistry/src/V1/DeleteApiVersionRequest.php @@ -30,6 +30,21 @@ class DeleteApiVersionRequest extends \Google\Protobuf\Internal\Message */ private $force = false; + /** + * @param string $name Required. The name of the version to delete. + * Format: `projects/*/locations/*/apis/*/versions/*` + * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiVersionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteArtifactRequest.php b/ApigeeRegistry/src/V1/DeleteArtifactRequest.php index 49372d74c175..cf648f27b1cd 100644 --- a/ApigeeRegistry/src/V1/DeleteArtifactRequest.php +++ b/ApigeeRegistry/src/V1/DeleteArtifactRequest.php @@ -23,6 +23,21 @@ class DeleteArtifactRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the artifact to delete. + * Format: `{parent}/artifacts/*` + * Please see {@see RegistryClient::artifactName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteArtifactRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/DeleteInstanceRequest.php b/ApigeeRegistry/src/V1/DeleteInstanceRequest.php index 7072b4b123cf..abba565a0950 100644 --- a/ApigeeRegistry/src/V1/DeleteInstanceRequest.php +++ b/ApigeeRegistry/src/V1/DeleteInstanceRequest.php @@ -23,6 +23,21 @@ class DeleteInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the Instance to delete. + * Format: `projects/*/locations/*/instances/*`. Please see + * {@see ProvisioningClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\DeleteInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetApiDeploymentRequest.php b/ApigeeRegistry/src/V1/GetApiDeploymentRequest.php index a58117005ea7..afe276b578b2 100644 --- a/ApigeeRegistry/src/V1/GetApiDeploymentRequest.php +++ b/ApigeeRegistry/src/V1/GetApiDeploymentRequest.php @@ -23,6 +23,21 @@ class GetApiDeploymentRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the deployment to retrieve. + * Format: `projects/*/locations/*/apis/*/deployments/*` + * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetApiDeploymentRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetApiRequest.php b/ApigeeRegistry/src/V1/GetApiRequest.php index 54c8ac14a988..facc07c7d402 100644 --- a/ApigeeRegistry/src/V1/GetApiRequest.php +++ b/ApigeeRegistry/src/V1/GetApiRequest.php @@ -23,6 +23,21 @@ class GetApiRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the API to retrieve. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetApiRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetApiSpecContentsRequest.php b/ApigeeRegistry/src/V1/GetApiSpecContentsRequest.php index c9f9c03e9a60..5e24fda3b988 100644 --- a/ApigeeRegistry/src/V1/GetApiSpecContentsRequest.php +++ b/ApigeeRegistry/src/V1/GetApiSpecContentsRequest.php @@ -23,6 +23,21 @@ class GetApiSpecContentsRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the spec whose contents should be retrieved. + * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` + * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetApiSpecContentsRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetApiSpecRequest.php b/ApigeeRegistry/src/V1/GetApiSpecRequest.php index b1b9f9eec4c2..b9d2541192e7 100644 --- a/ApigeeRegistry/src/V1/GetApiSpecRequest.php +++ b/ApigeeRegistry/src/V1/GetApiSpecRequest.php @@ -23,6 +23,21 @@ class GetApiSpecRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the spec to retrieve. + * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` + * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetApiSpecRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetApiVersionRequest.php b/ApigeeRegistry/src/V1/GetApiVersionRequest.php index d7debc11b908..a3e9d8f9154b 100644 --- a/ApigeeRegistry/src/V1/GetApiVersionRequest.php +++ b/ApigeeRegistry/src/V1/GetApiVersionRequest.php @@ -23,6 +23,21 @@ class GetApiVersionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the version to retrieve. + * Format: `projects/*/locations/*/apis/*/versions/*` + * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetApiVersionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetArtifactContentsRequest.php b/ApigeeRegistry/src/V1/GetArtifactContentsRequest.php index b81e4e69b6f3..dae16de3de84 100644 --- a/ApigeeRegistry/src/V1/GetArtifactContentsRequest.php +++ b/ApigeeRegistry/src/V1/GetArtifactContentsRequest.php @@ -23,6 +23,21 @@ class GetArtifactContentsRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the artifact whose contents should be retrieved. + * Format: `{parent}/artifacts/*` + * Please see {@see RegistryClient::artifactName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetArtifactContentsRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetArtifactRequest.php b/ApigeeRegistry/src/V1/GetArtifactRequest.php index be9ee8e46d03..d6a4d90817c3 100644 --- a/ApigeeRegistry/src/V1/GetArtifactRequest.php +++ b/ApigeeRegistry/src/V1/GetArtifactRequest.php @@ -23,6 +23,21 @@ class GetArtifactRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the artifact to retrieve. + * Format: `{parent}/artifacts/*` + * Please see {@see RegistryClient::artifactName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetArtifactRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/GetInstanceRequest.php b/ApigeeRegistry/src/V1/GetInstanceRequest.php index e86305e7c13b..5a543f33a744 100644 --- a/ApigeeRegistry/src/V1/GetInstanceRequest.php +++ b/ApigeeRegistry/src/V1/GetInstanceRequest.php @@ -23,6 +23,21 @@ class GetInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the Instance to retrieve. + * Format: `projects/*/locations/*/instances/*`. Please see + * {@see ProvisioningClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\GetInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ListApiDeploymentsRequest.php b/ApigeeRegistry/src/V1/ListApiDeploymentsRequest.php index 2cf875a3e099..d39b022ba014 100644 --- a/ApigeeRegistry/src/V1/ListApiDeploymentsRequest.php +++ b/ApigeeRegistry/src/V1/ListApiDeploymentsRequest.php @@ -48,6 +48,21 @@ class ListApiDeploymentsRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of deployments. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ListApiSpecsRequest.php b/ApigeeRegistry/src/V1/ListApiSpecsRequest.php index f491680b3301..62f1cb0fa1c9 100644 --- a/ApigeeRegistry/src/V1/ListApiSpecsRequest.php +++ b/ApigeeRegistry/src/V1/ListApiSpecsRequest.php @@ -48,6 +48,21 @@ class ListApiSpecsRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of specs. + * Format: `projects/*/locations/*/apis/*/versions/*` + * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\ListApiSpecsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ListApiVersionsRequest.php b/ApigeeRegistry/src/V1/ListApiVersionsRequest.php index 89d073da0ae7..34864ef7f5b7 100644 --- a/ApigeeRegistry/src/V1/ListApiVersionsRequest.php +++ b/ApigeeRegistry/src/V1/ListApiVersionsRequest.php @@ -48,6 +48,21 @@ class ListApiVersionsRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of versions. + * Format: `projects/*/locations/*/apis/*` + * Please see {@see RegistryClient::apiName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\ListApiVersionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ListApisRequest.php b/ApigeeRegistry/src/V1/ListApisRequest.php index 0114dfb2b39b..156e0018bcc4 100644 --- a/ApigeeRegistry/src/V1/ListApisRequest.php +++ b/ApigeeRegistry/src/V1/ListApisRequest.php @@ -48,6 +48,21 @@ class ListApisRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of APIs. + * Format: `projects/*/locations/*` + * Please see {@see RegistryClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\ListApisRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ListArtifactsRequest.php b/ApigeeRegistry/src/V1/ListArtifactsRequest.php index a2ec41114dd4..d659134df272 100644 --- a/ApigeeRegistry/src/V1/ListArtifactsRequest.php +++ b/ApigeeRegistry/src/V1/ListArtifactsRequest.php @@ -48,6 +48,21 @@ class ListArtifactsRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of artifacts. + * Format: `{parent}` + * Please see {@see RegistryClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\ApigeeRegistry\V1\ListArtifactsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/ReplaceArtifactRequest.php b/ApigeeRegistry/src/V1/ReplaceArtifactRequest.php index 252e155b2a66..a24aec494003 100644 --- a/ApigeeRegistry/src/V1/ReplaceArtifactRequest.php +++ b/ApigeeRegistry/src/V1/ReplaceArtifactRequest.php @@ -24,6 +24,22 @@ class ReplaceArtifactRequest extends \Google\Protobuf\Internal\Message */ private $artifact = null; + /** + * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact Required. The artifact to replace. + * + * The `name` field is used to identify the artifact to replace. + * Format: `{parent}/artifacts/*` + * + * @return \Google\Cloud\ApigeeRegistry\V1\ReplaceArtifactRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApigeeRegistry\V1\Artifact $artifact): self + { + return (new self()) + ->setArtifact($artifact); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/UpdateApiDeploymentRequest.php b/ApigeeRegistry/src/V1/UpdateApiDeploymentRequest.php index 1c90348fd500..01d3fb9f10ce 100644 --- a/ApigeeRegistry/src/V1/UpdateApiDeploymentRequest.php +++ b/ApigeeRegistry/src/V1/UpdateApiDeploymentRequest.php @@ -40,6 +40,27 @@ class UpdateApiDeploymentRequest extends \Google\Protobuf\Internal\Message */ private $allow_missing = false; + /** + * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment Required. The deployment to update. + * + * The `name` field is used to identify the deployment to update. + * Format: `projects/*/locations/*/apis/*/deployments/*` + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that + * are set in the request message (fields set to default values are ignored). + * If an asterisk "*" is specified, all fields are updated, including fields + * that are unspecified/default in the request. + * + * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiDeploymentRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setApiDeployment($apiDeployment) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/UpdateApiRequest.php b/ApigeeRegistry/src/V1/UpdateApiRequest.php index ecadbe94ccd6..bb75c4850b1b 100644 --- a/ApigeeRegistry/src/V1/UpdateApiRequest.php +++ b/ApigeeRegistry/src/V1/UpdateApiRequest.php @@ -40,6 +40,27 @@ class UpdateApiRequest extends \Google\Protobuf\Internal\Message */ private $allow_missing = false; + /** + * @param \Google\Cloud\ApigeeRegistry\V1\Api $api Required. The API to update. + * + * The `name` field is used to identify the API to update. + * Format: `projects/*/locations/*/apis/*` + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that + * are set in the request message (fields set to default values are ignored). + * If an asterisk "*" is specified, all fields are updated, including fields + * that are unspecified/default in the request. + * + * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApigeeRegistry\V1\Api $api, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setApi($api) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/UpdateApiSpecRequest.php b/ApigeeRegistry/src/V1/UpdateApiSpecRequest.php index 2f6a8061bd76..ec048cb4518f 100644 --- a/ApigeeRegistry/src/V1/UpdateApiSpecRequest.php +++ b/ApigeeRegistry/src/V1/UpdateApiSpecRequest.php @@ -40,6 +40,27 @@ class UpdateApiSpecRequest extends \Google\Protobuf\Internal\Message */ private $allow_missing = false; + /** + * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec Required. The spec to update. + * + * The `name` field is used to identify the spec to update. + * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that + * are set in the request message (fields set to default values are ignored). + * If an asterisk "*" is specified, all fields are updated, including fields + * that are unspecified/default in the request. + * + * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiSpecRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setApiSpec($apiSpec) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/UpdateApiVersionRequest.php b/ApigeeRegistry/src/V1/UpdateApiVersionRequest.php index 28bf752bafce..5216896779c0 100644 --- a/ApigeeRegistry/src/V1/UpdateApiVersionRequest.php +++ b/ApigeeRegistry/src/V1/UpdateApiVersionRequest.php @@ -40,6 +40,27 @@ class UpdateApiVersionRequest extends \Google\Protobuf\Internal\Message */ private $allow_missing = false; + /** + * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion Required. The version to update. + * + * The `name` field is used to identify the version to update. + * Format: `projects/*/locations/*/apis/*/versions/*` + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that + * are set in the request message (fields set to default values are ignored). + * If an asterisk "*" is specified, all fields are updated, including fields + * that are unspecified/default in the request. + * + * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiVersionRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setApiVersion($apiVersion) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/ApigeeRegistry/src/V1/resources/provisioning_descriptor_config.php b/ApigeeRegistry/src/V1/resources/provisioning_descriptor_config.php index 3d5ad2f83001..2bffad392f97 100644 --- a/ApigeeRegistry/src/V1/resources/provisioning_descriptor_config.php +++ b/ApigeeRegistry/src/V1/resources/provisioning_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteInstance' => [ 'longRunning' => [ @@ -22,8 +31,39 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetInstance' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Instance', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -35,17 +75,61 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/ApigeeRegistry/src/V1/resources/registry_descriptor_config.php b/ApigeeRegistry/src/V1/resources/registry_descriptor_config.php index 528952f6ae68..7d53a500a7e2 100644 --- a/ApigeeRegistry/src/V1/resources/registry_descriptor_config.php +++ b/ApigeeRegistry/src/V1/resources/registry_descriptor_config.php @@ -3,6 +3,234 @@ return [ 'interfaces' => [ 'google.cloud.apigeeregistry.v1.Registry' => [ + 'CreateApi' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateApiDeployment' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateApiSpec' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateApiVersion' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateArtifact' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteApi' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteApiDeployment' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteApiDeploymentRevision' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteApiSpec' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteApiSpecRevision' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteApiVersion' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteArtifact' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetApi' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetApiDeployment' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetApiSpec' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetApiSpecContents' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Api\HttpBody', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetApiVersion' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetArtifact' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetArtifactContents' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Api\HttpBody', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'ListApiDeploymentRevisions' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -12,6 +240,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApiDeployments', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListApiDeployments' => [ 'pageStreaming' => [ @@ -22,6 +260,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApiDeployments', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListApiSpecRevisions' => [ 'pageStreaming' => [ @@ -32,6 +280,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApiSpecs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListApiSpecs' => [ 'pageStreaming' => [ @@ -42,6 +300,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApiSpecs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiSpecsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListApiVersions' => [ 'pageStreaming' => [ @@ -52,6 +320,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApiVersions', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiVersionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListApis' => [ 'pageStreaming' => [ @@ -62,6 +340,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getApis', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApisResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListArtifacts' => [ 'pageStreaming' => [ @@ -72,8 +360,141 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getArtifacts', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListArtifactsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ReplaceArtifact' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', + 'headerParams' => [ + [ + 'keyName' => 'artifact.name', + 'fieldAccessors' => [ + 'getArtifact', + 'getName', + ], + ], + ], + ], + 'RollbackApiDeployment' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'RollbackApiSpec' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'TagApiDeploymentRevision' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'TagApiSpecRevision' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateApi' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', + 'headerParams' => [ + [ + 'keyName' => 'api.name', + 'fieldAccessors' => [ + 'getApi', + 'getName', + ], + ], + ], + ], + 'UpdateApiDeployment' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', + 'headerParams' => [ + [ + 'keyName' => 'api_deployment.name', + 'fieldAccessors' => [ + 'getApiDeployment', + 'getName', + ], + ], + ], + ], + 'UpdateApiSpec' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', + 'headerParams' => [ + [ + 'keyName' => 'api_spec.name', + 'fieldAccessors' => [ + 'getApiSpec', + 'getName', + ], + ], + ], + ], + 'UpdateApiVersion' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', + 'headerParams' => [ + [ + 'keyName' => 'api_version.name', + 'fieldAccessors' => [ + 'getApiVersion', + 'getName', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -85,17 +506,70 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'api' => 'projects/{project}/locations/{location}/apis/{api}', + 'apiDeployment' => 'projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}', + 'apiSpec' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}', + 'apiVersion' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}', + 'artifact' => 'projects/{project}/locations/{location}/artifacts/{artifact}', + 'location' => 'projects/{project}/locations/{location}', + 'projectLocationApiArtifact' => 'projects/{project}/locations/{location}/apis/{api}/artifacts/{artifact}', + 'projectLocationApiDeploymentArtifact' => 'projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}/artifacts/{artifact}', + 'projectLocationApiVersionArtifact' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/artifacts/{artifact}', + 'projectLocationApiVersionSpecArtifact' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}/artifacts/{artifact}', + 'projectLocationArtifact' => 'projects/{project}/locations/{location}/artifacts/{artifact}', + ], ], ], ]; diff --git a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/Client/ProvisioningClientTest.php b/ApigeeRegistry/tests/Unit/V1/Client/ProvisioningClientTest.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/Client/ProvisioningClientTest.php rename to ApigeeRegistry/tests/Unit/V1/Client/ProvisioningClientTest.php diff --git a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/Client/RegistryClientTest.php b/ApigeeRegistry/tests/Unit/V1/Client/RegistryClientTest.php similarity index 100% rename from owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/Client/RegistryClientTest.php rename to ApigeeRegistry/tests/Unit/V1/Client/RegistryClientTest.php diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/detach_lun.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/detach_lun.php index e1558bb7fd1a..0c6d33e02c83 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/detach_lun.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/detach_lun.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_DetachLun_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\DetachLunRequest; use Google\Cloud\BareMetalSolution\V2\Instance; use Google\Rpc\Status; @@ -42,10 +43,15 @@ function detach_lun_sample(string $formattedInstance, string $formattedLun): voi // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new DetachLunRequest()) + ->setInstance($formattedInstance) + ->setLun($formattedLun); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->detachLun($formattedInstance, $formattedLun); + $response = $bareMetalSolutionClient->detachLun($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_instance.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_instance.php index 9c1afdfd573e..48c31fef99b6 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_instance.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_instance.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_GetInstance_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\GetInstanceRequest; use Google\Cloud\BareMetalSolution\V2\Instance; /** @@ -38,10 +39,14 @@ function get_instance_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new GetInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Instance $response */ - $response = $bareMetalSolutionClient->getInstance($formattedName); + $response = $bareMetalSolutionClient->getInstance($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_lun.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_lun.php index 7b7fa306ff9e..a63216883ffa 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_lun.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_lun.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_GetLun_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\GetLunRequest; use Google\Cloud\BareMetalSolution\V2\Lun; /** @@ -38,10 +39,14 @@ function get_lun_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new GetLunRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Lun $response */ - $response = $bareMetalSolutionClient->getLun($formattedName); + $response = $bareMetalSolutionClient->getLun($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_network.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_network.php index 6608192fa26d..d2b6e29b05c9 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_network.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_network.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_GetNetwork_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\GetNetworkRequest; use Google\Cloud\BareMetalSolution\V2\Network; /** @@ -38,10 +39,14 @@ function get_network_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new GetNetworkRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Network $response */ - $response = $bareMetalSolutionClient->getNetwork($formattedName); + $response = $bareMetalSolutionClient->getNetwork($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_nfs_share.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_nfs_share.php index 7f08b24f46ed..ef5c5a017680 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_nfs_share.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_nfs_share.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_GetNfsShare_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\GetNfsShareRequest; use Google\Cloud\BareMetalSolution\V2\NfsShare; /** @@ -38,10 +39,14 @@ function get_nfs_share_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new GetNfsShareRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var NfsShare $response */ - $response = $bareMetalSolutionClient->getNfsShare($formattedName); + $response = $bareMetalSolutionClient->getNfsShare($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_volume.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_volume.php index 58cb053c27f3..2d648eda69b4 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_volume.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/get_volume.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_GetVolume_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\GetVolumeRequest; use Google\Cloud\BareMetalSolution\V2\Volume; /** @@ -38,10 +39,14 @@ function get_volume_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new GetVolumeRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Volume $response */ - $response = $bareMetalSolutionClient->getVolume($formattedName); + $response = $bareMetalSolutionClient->getVolume($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_instances.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_instances.php index 470e02c36b98..37d1bc492499 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_instances.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_instances.php @@ -25,8 +25,9 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListInstances_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; use Google\Cloud\BareMetalSolution\V2\Instance; +use Google\Cloud\BareMetalSolution\V2\ListInstancesRequest; /** * List servers in a given project and location. @@ -39,10 +40,14 @@ function list_instances_sample(string $formattedParent): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListInstancesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listInstances($formattedParent); + $response = $bareMetalSolutionClient->listInstances($request); /** @var Instance $element */ foreach ($response as $element) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_luns.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_luns.php index 73fab67760b8..3d4d2762b84a 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_luns.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_luns.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListLuns_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ListLunsRequest; use Google\Cloud\BareMetalSolution\V2\Lun; /** @@ -39,10 +40,14 @@ function list_luns_sample(string $formattedParent): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListLunsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listLuns($formattedParent); + $response = $bareMetalSolutionClient->listLuns($request); /** @var Lun $element */ foreach ($response as $element) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_network_usage.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_network_usage.php index 821d9fae467d..c19e50064006 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_network_usage.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_network_usage.php @@ -24,7 +24,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListNetworkUsage_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ListNetworkUsageRequest; use Google\Cloud\BareMetalSolution\V2\ListNetworkUsageResponse; /** @@ -39,10 +40,14 @@ function list_network_usage_sample(string $formattedLocation): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListNetworkUsageRequest()) + ->setLocation($formattedLocation); + // Call the API and handle any network failures. try { /** @var ListNetworkUsageResponse $response */ - $response = $bareMetalSolutionClient->listNetworkUsage($formattedLocation); + $response = $bareMetalSolutionClient->listNetworkUsage($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_networks.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_networks.php index 13a53bce96eb..2a587ec841b1 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_networks.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_networks.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListNetworks_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ListNetworksRequest; use Google\Cloud\BareMetalSolution\V2\Network; /** @@ -39,10 +40,14 @@ function list_networks_sample(string $formattedParent): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListNetworksRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listNetworks($formattedParent); + $response = $bareMetalSolutionClient->listNetworks($request); /** @var Network $element */ foreach ($response as $element) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_nfs_shares.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_nfs_shares.php index a976dd0e41a6..099316c04aab 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_nfs_shares.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_nfs_shares.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListNfsShares_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ListNfsSharesRequest; use Google\Cloud\BareMetalSolution\V2\NfsShare; /** @@ -39,10 +40,14 @@ function list_nfs_shares_sample(string $formattedParent): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListNfsSharesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listNfsShares($formattedParent); + $response = $bareMetalSolutionClient->listNfsShares($request); /** @var NfsShare $element */ foreach ($response as $element) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_volumes.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_volumes.php index 37dfac28bcfe..ff93f6dc6f3e 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_volumes.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/list_volumes.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ListVolumes_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ListVolumesRequest; use Google\Cloud\BareMetalSolution\V2\Volume; /** @@ -39,10 +40,14 @@ function list_volumes_sample(string $formattedParent): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ListVolumesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listVolumes($formattedParent); + $response = $bareMetalSolutionClient->listVolumes($request); /** @var Volume $element */ foreach ($response as $element) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/reset_instance.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/reset_instance.php index 6de1ccbebc81..ca2f975dc539 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/reset_instance.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/reset_instance.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ResetInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ResetInstanceRequest; use Google\Cloud\BareMetalSolution\V2\ResetInstanceResponse; use Google\Rpc\Status; @@ -41,10 +42,14 @@ function reset_instance_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ResetInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->resetInstance($formattedName); + $response = $bareMetalSolutionClient->resetInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/resize_volume.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/resize_volume.php index ae0428c73090..b70e3c59c86c 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/resize_volume.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/resize_volume.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_ResizeVolume_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\ResizeVolumeRequest; use Google\Cloud\BareMetalSolution\V2\Volume; use Google\Rpc\Status; @@ -40,10 +41,14 @@ function resize_volume_sample(string $formattedVolume): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new ResizeVolumeRequest()) + ->setVolume($formattedVolume); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->resizeVolume($formattedVolume); + $response = $bareMetalSolutionClient->resizeVolume($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/start_instance.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/start_instance.php index 9d0fc4aae848..575ea412e818 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/start_instance.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/start_instance.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_StartInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\StartInstanceRequest; use Google\Cloud\BareMetalSolution\V2\StartInstanceResponse; use Google\Rpc\Status; @@ -40,10 +41,14 @@ function start_instance_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new StartInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->startInstance($formattedName); + $response = $bareMetalSolutionClient->startInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/stop_instance.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/stop_instance.php index 98838551484b..2d53458a921f 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/stop_instance.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/stop_instance.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_StopInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\StopInstanceRequest; use Google\Cloud\BareMetalSolution\V2\StopInstanceResponse; use Google\Rpc\Status; @@ -40,10 +41,14 @@ function stop_instance_sample(string $formattedName): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); + // Prepare the request message. + $request = (new StopInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->stopInstance($formattedName); + $response = $bareMetalSolutionClient->stopInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_instance.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_instance.php index 167e7965f5a8..61d2289e3118 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_instance.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_instance.php @@ -25,8 +25,9 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_UpdateInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; use Google\Cloud\BareMetalSolution\V2\Instance; +use Google\Cloud\BareMetalSolution\V2\UpdateInstanceRequest; use Google\Rpc\Status; /** @@ -43,13 +44,15 @@ function update_instance_sample(): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $instance = new Instance(); + $request = (new UpdateInstanceRequest()) + ->setInstance($instance); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateInstance($instance); + $response = $bareMetalSolutionClient->updateInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_network.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_network.php index dad0ff6cce81..b5ef51b12583 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_network.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_network.php @@ -25,8 +25,9 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_UpdateNetwork_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; use Google\Cloud\BareMetalSolution\V2\Network; +use Google\Cloud\BareMetalSolution\V2\UpdateNetworkRequest; use Google\Rpc\Status; /** @@ -43,13 +44,15 @@ function update_network_sample(): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $network = new Network(); + $request = (new UpdateNetworkRequest()) + ->setNetwork($network); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateNetwork($network); + $response = $bareMetalSolutionClient->updateNetwork($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_nfs_share.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_nfs_share.php index e07dce96ca71..46e316450ed6 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_nfs_share.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_nfs_share.php @@ -25,8 +25,9 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_UpdateNfsShare_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; use Google\Cloud\BareMetalSolution\V2\NfsShare; +use Google\Cloud\BareMetalSolution\V2\UpdateNfsShareRequest; use Google\Rpc\Status; /** @@ -43,13 +44,15 @@ function update_nfs_share_sample(): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $nfsShare = new NfsShare(); + $request = (new UpdateNfsShareRequest()) + ->setNfsShare($nfsShare); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateNfsShare($nfsShare); + $response = $bareMetalSolutionClient->updateNfsShare($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_volume.php b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_volume.php index fc820199694a..66065b9c3b7d 100644 --- a/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_volume.php +++ b/BareMetalSolution/samples/V2/BareMetalSolutionClient/update_volume.php @@ -25,7 +25,8 @@ // [START baremetalsolution_v2_generated_BareMetalSolution_UpdateVolume_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BareMetalSolution\V2\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\Client\BareMetalSolutionClient; +use Google\Cloud\BareMetalSolution\V2\UpdateVolumeRequest; use Google\Cloud\BareMetalSolution\V2\Volume; use Google\Rpc\Status; @@ -43,13 +44,15 @@ function update_volume_sample(): void // Create a client. $bareMetalSolutionClient = new BareMetalSolutionClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $volume = new Volume(); + $request = (new UpdateVolumeRequest()) + ->setVolume($volume); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateVolume($volume); + $response = $bareMetalSolutionClient->updateVolume($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/Client/BareMetalSolutionClient.php b/BareMetalSolution/src/V2/Client/BareMetalSolutionClient.php similarity index 100% rename from owl-bot-staging/BareMetalSolution/v2/src/V2/Client/BareMetalSolutionClient.php rename to BareMetalSolution/src/V2/Client/BareMetalSolutionClient.php diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/Client/BaseClient/BareMetalSolutionBaseClient.php b/BareMetalSolution/src/V2/Client/BaseClient/BareMetalSolutionBaseClient.php similarity index 100% rename from owl-bot-staging/BareMetalSolution/v2/src/V2/Client/BaseClient/BareMetalSolutionBaseClient.php rename to BareMetalSolution/src/V2/Client/BaseClient/BareMetalSolutionBaseClient.php diff --git a/BareMetalSolution/src/V2/DetachLunRequest.php b/BareMetalSolution/src/V2/DetachLunRequest.php index 1396be0bb106..ea2e1665087a 100644 --- a/BareMetalSolution/src/V2/DetachLunRequest.php +++ b/BareMetalSolution/src/V2/DetachLunRequest.php @@ -28,6 +28,23 @@ class DetachLunRequest extends \Google\Protobuf\Internal\Message */ private $lun = ''; + /** + * @param string $instance Required. Name of the instance. Please see + * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. + * @param string $lun Required. Name of the Lun to detach. Please see + * {@see BareMetalSolutionClient::lunName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\DetachLunRequest + * + * @experimental + */ + public static function build(string $instance, string $lun): self + { + return (new self()) + ->setInstance($instance) + ->setLun($lun); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/GetInstanceRequest.php b/BareMetalSolution/src/V2/GetInstanceRequest.php index 3dbd85c7a179..d7e28a3e1c91 100644 --- a/BareMetalSolution/src/V2/GetInstanceRequest.php +++ b/BareMetalSolution/src/V2/GetInstanceRequest.php @@ -22,6 +22,20 @@ class GetInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\GetInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/GetLunRequest.php b/BareMetalSolution/src/V2/GetLunRequest.php index a51e11a56539..0a050a1b3825 100644 --- a/BareMetalSolution/src/V2/GetLunRequest.php +++ b/BareMetalSolution/src/V2/GetLunRequest.php @@ -22,6 +22,20 @@ class GetLunRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::lunName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\GetLunRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/GetNetworkRequest.php b/BareMetalSolution/src/V2/GetNetworkRequest.php index 03373aad9acd..f1ab274ee7b3 100644 --- a/BareMetalSolution/src/V2/GetNetworkRequest.php +++ b/BareMetalSolution/src/V2/GetNetworkRequest.php @@ -22,6 +22,20 @@ class GetNetworkRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::networkName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\GetNetworkRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/GetNfsShareRequest.php b/BareMetalSolution/src/V2/GetNfsShareRequest.php index f44f00459a4a..7699023eb890 100644 --- a/BareMetalSolution/src/V2/GetNfsShareRequest.php +++ b/BareMetalSolution/src/V2/GetNfsShareRequest.php @@ -22,6 +22,20 @@ class GetNfsShareRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::nFSShareName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\GetNfsShareRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/GetVolumeRequest.php b/BareMetalSolution/src/V2/GetVolumeRequest.php index dce61ec5ad8a..50e02fdc1e89 100644 --- a/BareMetalSolution/src/V2/GetVolumeRequest.php +++ b/BareMetalSolution/src/V2/GetVolumeRequest.php @@ -22,6 +22,20 @@ class GetVolumeRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\GetVolumeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListInstancesRequest.php b/BareMetalSolution/src/V2/ListInstancesRequest.php index 47e2f3c3a2c7..316a7a6ebd7b 100644 --- a/BareMetalSolution/src/V2/ListInstancesRequest.php +++ b/BareMetalSolution/src/V2/ListInstancesRequest.php @@ -41,6 +41,20 @@ class ListInstancesRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. Parent value for ListInstancesRequest. Please see + * {@see BareMetalSolutionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListInstancesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListLunsRequest.php b/BareMetalSolution/src/V2/ListLunsRequest.php index 19536bd8dacf..ed41afcbe5ec 100644 --- a/BareMetalSolution/src/V2/ListLunsRequest.php +++ b/BareMetalSolution/src/V2/ListLunsRequest.php @@ -35,6 +35,20 @@ class ListLunsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Parent value for ListLunsRequest. Please see + * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListLunsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListNetworkUsageRequest.php b/BareMetalSolution/src/V2/ListNetworkUsageRequest.php index 8960cd3a0ae0..d74b673fd85a 100644 --- a/BareMetalSolution/src/V2/ListNetworkUsageRequest.php +++ b/BareMetalSolution/src/V2/ListNetworkUsageRequest.php @@ -22,6 +22,20 @@ class ListNetworkUsageRequest extends \Google\Protobuf\Internal\Message */ private $location = ''; + /** + * @param string $location Required. Parent value (project and location). Please see + * {@see BareMetalSolutionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListNetworkUsageRequest + * + * @experimental + */ + public static function build(string $location): self + { + return (new self()) + ->setLocation($location); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListNetworksRequest.php b/BareMetalSolution/src/V2/ListNetworksRequest.php index e2eb42262ab6..2e78fca0aff7 100644 --- a/BareMetalSolution/src/V2/ListNetworksRequest.php +++ b/BareMetalSolution/src/V2/ListNetworksRequest.php @@ -41,6 +41,20 @@ class ListNetworksRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. Parent value for ListNetworksRequest. Please see + * {@see BareMetalSolutionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListNetworksRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListNfsSharesRequest.php b/BareMetalSolution/src/V2/ListNfsSharesRequest.php index 11b01340a77a..0c079132692a 100644 --- a/BareMetalSolution/src/V2/ListNfsSharesRequest.php +++ b/BareMetalSolution/src/V2/ListNfsSharesRequest.php @@ -41,6 +41,20 @@ class ListNfsSharesRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. Parent value for ListNfsSharesRequest. Please see + * {@see BareMetalSolutionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListNfsSharesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ListVolumesRequest.php b/BareMetalSolution/src/V2/ListVolumesRequest.php index 1d11bac9d6a2..c253e4ea61bd 100644 --- a/BareMetalSolution/src/V2/ListVolumesRequest.php +++ b/BareMetalSolution/src/V2/ListVolumesRequest.php @@ -41,6 +41,20 @@ class ListVolumesRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. Parent value for ListVolumesRequest. Please see + * {@see BareMetalSolutionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ListVolumesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ResetInstanceRequest.php b/BareMetalSolution/src/V2/ResetInstanceRequest.php index 099819a2ec7b..f9f90000b755 100644 --- a/BareMetalSolution/src/V2/ResetInstanceRequest.php +++ b/BareMetalSolution/src/V2/ResetInstanceRequest.php @@ -22,6 +22,20 @@ class ResetInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\ResetInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/ResizeVolumeRequest.php b/BareMetalSolution/src/V2/ResizeVolumeRequest.php index df8b77f75bd3..46fe33196be2 100644 --- a/BareMetalSolution/src/V2/ResizeVolumeRequest.php +++ b/BareMetalSolution/src/V2/ResizeVolumeRequest.php @@ -28,6 +28,22 @@ class ResizeVolumeRequest extends \Google\Protobuf\Internal\Message */ private $size_gib = 0; + /** + * @param string $volume Required. Volume to resize. Please see + * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. + * @param int $sizeGib New Volume size, in GiB. + * + * @return \Google\Cloud\BareMetalSolution\V2\ResizeVolumeRequest + * + * @experimental + */ + public static function build(string $volume, int $sizeGib): self + { + return (new self()) + ->setVolume($volume) + ->setSizeGib($sizeGib); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/StartInstanceRequest.php b/BareMetalSolution/src/V2/StartInstanceRequest.php index 8517abb3432a..ac899e87e1d8 100644 --- a/BareMetalSolution/src/V2/StartInstanceRequest.php +++ b/BareMetalSolution/src/V2/StartInstanceRequest.php @@ -22,6 +22,20 @@ class StartInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\StartInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/StopInstanceRequest.php b/BareMetalSolution/src/V2/StopInstanceRequest.php index 5b499d0c58a0..93a98e71ac40 100644 --- a/BareMetalSolution/src/V2/StopInstanceRequest.php +++ b/BareMetalSolution/src/V2/StopInstanceRequest.php @@ -22,6 +22,20 @@ class StopInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\BareMetalSolution\V2\StopInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/UpdateInstanceRequest.php b/BareMetalSolution/src/V2/UpdateInstanceRequest.php index 80f499e2fa88..678f9a38bd86 100644 --- a/BareMetalSolution/src/V2/UpdateInstanceRequest.php +++ b/BareMetalSolution/src/V2/UpdateInstanceRequest.php @@ -34,6 +34,28 @@ class UpdateInstanceRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\BareMetalSolution\V2\Instance $instance Required. The server to update. + * + * The `name` field is used to identify the instance to update. + * Format: projects/{project}/locations/{location}/instances/{instance} + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. + * The currently supported fields are: + * `labels` + * `hyperthreading_enabled` + * `os_image` + * + * @return \Google\Cloud\BareMetalSolution\V2\UpdateInstanceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BareMetalSolution\V2\Instance $instance, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setInstance($instance) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/UpdateNetworkRequest.php b/BareMetalSolution/src/V2/UpdateNetworkRequest.php index 36996aef2ef5..729e43d1a456 100644 --- a/BareMetalSolution/src/V2/UpdateNetworkRequest.php +++ b/BareMetalSolution/src/V2/UpdateNetworkRequest.php @@ -32,6 +32,26 @@ class UpdateNetworkRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\BareMetalSolution\V2\Network $network Required. The network to update. + * + * The `name` field is used to identify the instance to update. + * Format: projects/{project}/locations/{location}/networks/{network} + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. + * The only currently supported fields are: + * `labels`, `reservations` + * + * @return \Google\Cloud\BareMetalSolution\V2\UpdateNetworkRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BareMetalSolution\V2\Network $network, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNetwork($network) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/UpdateNfsShareRequest.php b/BareMetalSolution/src/V2/UpdateNfsShareRequest.php index 2c760d8ea88b..73c61698b019 100644 --- a/BareMetalSolution/src/V2/UpdateNfsShareRequest.php +++ b/BareMetalSolution/src/V2/UpdateNfsShareRequest.php @@ -32,6 +32,26 @@ class UpdateNfsShareRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\BareMetalSolution\V2\NfsShare $nfsShare Required. The NFS share to update. + * + * The `name` field is used to identify the NFS share to update. + * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. + * The only currently supported fields are: + * `labels` + * + * @return \Google\Cloud\BareMetalSolution\V2\UpdateNfsShareRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BareMetalSolution\V2\NfsShare $nfsShare, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNfsShare($nfsShare) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/UpdateVolumeRequest.php b/BareMetalSolution/src/V2/UpdateVolumeRequest.php index be5ca4b0f422..149f0ecdbe27 100644 --- a/BareMetalSolution/src/V2/UpdateVolumeRequest.php +++ b/BareMetalSolution/src/V2/UpdateVolumeRequest.php @@ -36,6 +36,30 @@ class UpdateVolumeRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\BareMetalSolution\V2\Volume $volume Required. The volume to update. + * + * The `name` field is used to identify the volume to update. + * Format: projects/{project}/locations/{location}/volumes/{volume} + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. + * The only currently supported fields are: + * `snapshot_auto_delete_behavior` + * `snapshot_schedule_policy_name` + * 'labels' + * 'snapshot_enabled' + * 'snapshot_reservation_detail.reserved_space_percent' + * + * @return \Google\Cloud\BareMetalSolution\V2\UpdateVolumeRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BareMetalSolution\V2\Volume $volume, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setVolume($volume) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BareMetalSolution/src/V2/resources/bare_metal_solution_descriptor_config.php b/BareMetalSolution/src/V2/resources/bare_metal_solution_descriptor_config.php index 0ba834ac2936..ba98f4d93a1d 100644 --- a/BareMetalSolution/src/V2/resources/bare_metal_solution_descriptor_config.php +++ b/BareMetalSolution/src/V2/resources/bare_metal_solution_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'instance', + 'fieldAccessors' => [ + 'getInstance', + ], + ], + ], ], 'ResetInstance' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ResizeVolume' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'volume', + 'fieldAccessors' => [ + 'getVolume', + ], + ], + ], ], 'StartInstance' => [ 'longRunning' => [ @@ -42,6 +69,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'StopInstance' => [ 'longRunning' => [ @@ -52,6 +88,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateInstance' => [ 'longRunning' => [ @@ -62,6 +107,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'instance.name', + 'fieldAccessors' => [ + 'getInstance', + 'getName', + ], + ], + ], ], 'UpdateNetwork' => [ 'longRunning' => [ @@ -72,6 +127,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'network.name', + 'fieldAccessors' => [ + 'getNetwork', + 'getName', + ], + ], + ], ], 'UpdateNfsShare' => [ 'longRunning' => [ @@ -82,6 +147,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'nfs_share.name', + 'fieldAccessors' => [ + 'getNfsShare', + 'getName', + ], + ], + ], ], 'UpdateVolume' => [ 'longRunning' => [ @@ -92,6 +167,76 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'volume.name', + 'fieldAccessors' => [ + 'getVolume', + 'getName', + ], + ], + ], + ], + 'GetInstance' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Instance', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetLun' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Lun', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNetwork' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Network', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNfsShare' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\NfsShare', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetVolume' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Volume', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListInstances' => [ 'pageStreaming' => [ @@ -102,6 +247,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getInstances', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListInstancesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListLuns' => [ 'pageStreaming' => [ @@ -112,6 +267,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLuns', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListLunsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNetworkUsage' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNetworkUsageResponse', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], ], 'ListNetworks' => [ 'pageStreaming' => [ @@ -122,6 +299,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getNetworks', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNetworksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListNfsShares' => [ 'pageStreaming' => [ @@ -132,6 +319,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getNfsShares', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNfsSharesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListVolumes' => [ 'pageStreaming' => [ @@ -142,6 +339,25 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getVolumes', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListVolumesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'templateMap' => [ + 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', + 'location' => 'projects/{project}/locations/{location}', + 'lun' => 'projects/{project}/locations/{location}/volumes/{volume}/luns/{lun}', + 'nFSShare' => 'projects/{project}/locations/{location}/nfsShares/{nfs_share}', + 'network' => 'projects/{project}/locations/{location}/networks/{network}', + 'serverNetworkTemplate' => 'projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}', + 'volume' => 'projects/{project}/locations/{location}/volumes/{volume}', ], ], ], diff --git a/owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/Client/BareMetalSolutionClientTest.php b/BareMetalSolution/tests/Unit/V2/Client/BareMetalSolutionClientTest.php similarity index 100% rename from owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/Client/BareMetalSolutionClientTest.php rename to BareMetalSolution/tests/Unit/V2/Client/BareMetalSolutionClientTest.php diff --git a/Batch/samples/V1/BatchServiceClient/create_job.php b/Batch/samples/V1/BatchServiceClient/create_job.php index 991cf626dd63..934c0ac7a216 100644 --- a/Batch/samples/V1/BatchServiceClient/create_job.php +++ b/Batch/samples/V1/BatchServiceClient/create_job.php @@ -24,7 +24,8 @@ // [START batch_v1_generated_BatchService_CreateJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Batch\V1\CreateJobRequest; use Google\Cloud\Batch\V1\Job; use Google\Cloud\Batch\V1\TaskGroup; use Google\Cloud\Batch\V1\TaskSpec; @@ -41,18 +42,21 @@ function create_job_sample(string $formattedParent): void // Create a client. $batchServiceClient = new BatchServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $jobTaskGroupsTaskSpec = new TaskSpec(); $taskGroup = (new TaskGroup()) ->setTaskSpec($jobTaskGroupsTaskSpec); $jobTaskGroups = [$taskGroup,]; $job = (new Job()) ->setTaskGroups($jobTaskGroups); + $request = (new CreateJobRequest()) + ->setParent($formattedParent) + ->setJob($job); // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $batchServiceClient->createJob($formattedParent, $job); + $response = $batchServiceClient->createJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Batch/samples/V1/BatchServiceClient/delete_job.php b/Batch/samples/V1/BatchServiceClient/delete_job.php index a0bdd2e14198..77f3076ec644 100644 --- a/Batch/samples/V1/BatchServiceClient/delete_job.php +++ b/Batch/samples/V1/BatchServiceClient/delete_job.php @@ -25,7 +25,8 @@ // [START batch_v1_generated_BatchService_DeleteJob_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Batch\V1\DeleteJobRequest; use Google\Rpc\Status; /** @@ -42,10 +43,13 @@ function delete_job_sample(): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = new DeleteJobRequest(); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $batchServiceClient->deleteJob(); + $response = $batchServiceClient->deleteJob($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Batch/samples/V1/BatchServiceClient/get_job.php b/Batch/samples/V1/BatchServiceClient/get_job.php index a8ecbe7902ad..1214ecab96f4 100644 --- a/Batch/samples/V1/BatchServiceClient/get_job.php +++ b/Batch/samples/V1/BatchServiceClient/get_job.php @@ -24,7 +24,8 @@ // [START batch_v1_generated_BatchService_GetJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Batch\V1\GetJobRequest; use Google\Cloud\Batch\V1\Job; /** @@ -38,10 +39,14 @@ function get_job_sample(string $formattedName): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = (new GetJobRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $batchServiceClient->getJob($formattedName); + $response = $batchServiceClient->getJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Batch/samples/V1/BatchServiceClient/get_location.php b/Batch/samples/V1/BatchServiceClient/get_location.php index e0111df3de2d..9c4f203431bb 100644 --- a/Batch/samples/V1/BatchServiceClient/get_location.php +++ b/Batch/samples/V1/BatchServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START batch_v1_generated_BatchService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $batchServiceClient->getLocation(); + $response = $batchServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Batch/samples/V1/BatchServiceClient/get_task.php b/Batch/samples/V1/BatchServiceClient/get_task.php index aef0951f5fe6..5ef1d86cd668 100644 --- a/Batch/samples/V1/BatchServiceClient/get_task.php +++ b/Batch/samples/V1/BatchServiceClient/get_task.php @@ -24,7 +24,8 @@ // [START batch_v1_generated_BatchService_GetTask_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Batch\V1\GetTaskRequest; use Google\Cloud\Batch\V1\Task; /** @@ -38,10 +39,14 @@ function get_task_sample(string $formattedName): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = (new GetTaskRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Task $response */ - $response = $batchServiceClient->getTask($formattedName); + $response = $batchServiceClient->getTask($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Batch/samples/V1/BatchServiceClient/list_jobs.php b/Batch/samples/V1/BatchServiceClient/list_jobs.php index fab86df47e46..4113b01dae98 100644 --- a/Batch/samples/V1/BatchServiceClient/list_jobs.php +++ b/Batch/samples/V1/BatchServiceClient/list_jobs.php @@ -25,8 +25,9 @@ // [START batch_v1_generated_BatchService_ListJobs_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; use Google\Cloud\Batch\V1\Job; +use Google\Cloud\Batch\V1\ListJobsRequest; /** * List all Jobs for a project within a region. @@ -42,10 +43,13 @@ function list_jobs_sample(): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = new ListJobsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $batchServiceClient->listJobs(); + $response = $batchServiceClient->listJobs($request); /** @var Job $element */ foreach ($response as $element) { diff --git a/Batch/samples/V1/BatchServiceClient/list_locations.php b/Batch/samples/V1/BatchServiceClient/list_locations.php index 13ecc80c17d8..afdd8f478b9e 100644 --- a/Batch/samples/V1/BatchServiceClient/list_locations.php +++ b/Batch/samples/V1/BatchServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START batch_v1_generated_BatchService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $batchServiceClient->listLocations(); + $response = $batchServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/Batch/samples/V1/BatchServiceClient/list_tasks.php b/Batch/samples/V1/BatchServiceClient/list_tasks.php index 3b7f3b1a700d..66aa3eec1521 100644 --- a/Batch/samples/V1/BatchServiceClient/list_tasks.php +++ b/Batch/samples/V1/BatchServiceClient/list_tasks.php @@ -25,7 +25,8 @@ // [START batch_v1_generated_BatchService_ListTasks_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\Batch\V1\BatchServiceClient; +use Google\Cloud\Batch\V1\Client\BatchServiceClient; +use Google\Cloud\Batch\V1\ListTasksRequest; use Google\Cloud\Batch\V1\Task; /** @@ -41,10 +42,14 @@ function list_tasks_sample(string $formattedParent): void // Create a client. $batchServiceClient = new BatchServiceClient(); + // Prepare the request message. + $request = (new ListTasksRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $batchServiceClient->listTasks($formattedParent); + $response = $batchServiceClient->listTasks($request); /** @var Task $element */ foreach ($response as $element) { diff --git a/owl-bot-staging/Batch/v1/src/V1/Client/BaseClient/BatchServiceBaseClient.php b/Batch/src/V1/Client/BaseClient/BatchServiceBaseClient.php similarity index 100% rename from owl-bot-staging/Batch/v1/src/V1/Client/BaseClient/BatchServiceBaseClient.php rename to Batch/src/V1/Client/BaseClient/BatchServiceBaseClient.php diff --git a/owl-bot-staging/Batch/v1/src/V1/Client/BatchServiceClient.php b/Batch/src/V1/Client/BatchServiceClient.php similarity index 100% rename from owl-bot-staging/Batch/v1/src/V1/Client/BatchServiceClient.php rename to Batch/src/V1/Client/BatchServiceClient.php diff --git a/Batch/src/V1/CreateJobRequest.php b/Batch/src/V1/CreateJobRequest.php index c0febde269b9..bafca4b7b3d8 100644 --- a/Batch/src/V1/CreateJobRequest.php +++ b/Batch/src/V1/CreateJobRequest.php @@ -58,6 +58,33 @@ class CreateJobRequest extends \Google\Protobuf\Internal\Message */ private $request_id = ''; + /** + * @param string $parent Required. The parent resource name where the Job will be created. + * Pattern: "projects/{project}/locations/{location}" + * Please see {@see BatchServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Batch\V1\Job $job Required. The Job to create. + * @param string $jobId ID used to uniquely identify the Job within its parent scope. + * This field should contain at most 63 characters and must start with + * lowercase characters. + * Only lowercase characters, numbers and '-' are accepted. + * The '-' character cannot be the first or the last one. + * A system generated ID will be used if the field is not set. + * + * The job.name field in the request will be ignored and the created resource + * name of the Job will be "{parent}/jobs/{job_id}". + * + * @return \Google\Cloud\Batch\V1\CreateJobRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Batch\V1\Job $job, string $jobId): self + { + return (new self()) + ->setParent($parent) + ->setJob($job) + ->setJobId($jobId); + } + /** * Constructor. * diff --git a/Batch/src/V1/DeleteJobRequest.php b/Batch/src/V1/DeleteJobRequest.php index 2971ff2ea860..76843ae7e020 100644 --- a/Batch/src/V1/DeleteJobRequest.php +++ b/Batch/src/V1/DeleteJobRequest.php @@ -44,6 +44,19 @@ class DeleteJobRequest extends \Google\Protobuf\Internal\Message */ private $request_id = ''; + /** + * @param string $name Job name. + * + * @return \Google\Cloud\Batch\V1\DeleteJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Batch/src/V1/GetJobRequest.php b/Batch/src/V1/GetJobRequest.php index a14d47d59368..6bd20c416e71 100644 --- a/Batch/src/V1/GetJobRequest.php +++ b/Batch/src/V1/GetJobRequest.php @@ -22,6 +22,20 @@ class GetJobRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Job name. Please see + * {@see BatchServiceClient::jobName()} for help formatting this field. + * + * @return \Google\Cloud\Batch\V1\GetJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Batch/src/V1/GetTaskRequest.php b/Batch/src/V1/GetTaskRequest.php index abb7d163e0db..1fcad29bc88e 100644 --- a/Batch/src/V1/GetTaskRequest.php +++ b/Batch/src/V1/GetTaskRequest.php @@ -22,6 +22,20 @@ class GetTaskRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Task name. Please see + * {@see BatchServiceClient::taskName()} for help formatting this field. + * + * @return \Google\Cloud\Batch\V1\GetTaskRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Batch/src/V1/ListJobsRequest.php b/Batch/src/V1/ListJobsRequest.php index 142960ab137d..e87b663dd4b5 100644 --- a/Batch/src/V1/ListJobsRequest.php +++ b/Batch/src/V1/ListJobsRequest.php @@ -40,6 +40,19 @@ class ListJobsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Parent path. + * + * @return \Google\Cloud\Batch\V1\ListJobsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/Batch/src/V1/ListTasksRequest.php b/Batch/src/V1/ListTasksRequest.php index 5764afa4720a..cba6326bf973 100644 --- a/Batch/src/V1/ListTasksRequest.php +++ b/Batch/src/V1/ListTasksRequest.php @@ -44,6 +44,22 @@ class ListTasksRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Name of a TaskGroup from which Tasks are being requested. + * Pattern: + * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" + * Please see {@see BatchServiceClient::taskGroupName()} for help formatting this field. + * + * @return \Google\Cloud\Batch\V1\ListTasksRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/Batch/src/V1/resources/batch_service_descriptor_config.php b/Batch/src/V1/resources/batch_service_descriptor_config.php index febed4cf12e5..3b05da1b865f 100644 --- a/Batch/src/V1/resources/batch_service_descriptor_config.php +++ b/Batch/src/V1/resources/batch_service_descriptor_config.php @@ -12,6 +12,51 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'CreateJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Batch\V1\Job', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'GetJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Batch\V1\Job', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetTask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Batch\V1\Task', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListJobs' => [ 'pageStreaming' => [ @@ -22,6 +67,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getJobs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Batch\V1\ListJobsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListTasks' => [ 'pageStreaming' => [ @@ -32,8 +87,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getTasks', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Batch\V1\ListTasksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -45,8 +120,24 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], + 'templateMap' => [ + 'job' => 'projects/{project}/locations/{location}/jobs/{job}', + 'location' => 'projects/{project}/locations/{location}', + 'task' => 'projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}/tasks/{task}', + 'taskGroup' => 'projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}', + ], ], ], ]; diff --git a/owl-bot-staging/Batch/v1/tests/Unit/V1/Client/BatchServiceClientTest.php b/Batch/tests/Unit/V1/Client/BatchServiceClientTest.php similarity index 100% rename from owl-bot-staging/Batch/v1/tests/Unit/V1/Client/BatchServiceClientTest.php rename to Batch/tests/Unit/V1/Client/BatchServiceClientTest.php diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/create_app_connection.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/create_app_connection.php index ebee98608822..221fd47b0158 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/create_app_connection.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/create_app_connection.php @@ -28,7 +28,8 @@ use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Type; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\CreateAppConnectionRequest; use Google\Rpc\Status; /** @@ -53,7 +54,7 @@ function create_app_connection_sample( // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $appConnectionApplicationEndpoint = (new ApplicationEndpoint()) ->setHost($appConnectionApplicationEndpointHost) ->setPort($appConnectionApplicationEndpointPort); @@ -61,11 +62,14 @@ function create_app_connection_sample( ->setName($appConnectionName) ->setType($appConnectionType) ->setApplicationEndpoint($appConnectionApplicationEndpoint); + $request = (new CreateAppConnectionRequest()) + ->setParent($formattedParent) + ->setAppConnection($appConnection); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->createAppConnection($formattedParent, $appConnection); + $response = $appConnectionsServiceClient->createAppConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/delete_app_connection.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/delete_app_connection.php index b0a9d5f7b4b7..402dcc877cdf 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/delete_app_connection.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/delete_app_connection.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_DeleteAppConnection_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\DeleteAppConnectionRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_app_connection_sample(string $formattedName): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = (new DeleteAppConnectionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->deleteAppConnection($formattedName); + $response = $appConnectionsServiceClient->deleteAppConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_app_connection.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_app_connection.php index 741db00d3f13..c5aa488fb4bc 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_app_connection.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_app_connection.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_GetAppConnection_sync] use Google\ApiCore\ApiException; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\GetAppConnectionRequest; /** * Gets details of a single AppConnection. @@ -39,10 +40,14 @@ function get_app_connection_sample(string $formattedName): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = (new GetAppConnectionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var AppConnection $response */ - $response = $appConnectionsServiceClient->getAppConnection($formattedName); + $response = $appConnectionsServiceClient->getAppConnection($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_iam_policy.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_iam_policy.php index 4b9a5609e5d9..4e638a5cd999 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_iam_policy.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $appConnectionsServiceClient->getIamPolicy($resource); + $response = $appConnectionsServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_location.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_location.php index c8dba622fa3e..dbf101df5735 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_location.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $appConnectionsServiceClient->getLocation(); + $response = $appConnectionsServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_app_connections.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_app_connections.php index fa81da9dc6e7..b82bce085b23 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_app_connections.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_app_connections.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsRequest; /** * Lists AppConnections in a given project and location. @@ -40,10 +41,14 @@ function list_app_connections_sample(string $formattedParent): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = (new ListAppConnectionsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appConnectionsServiceClient->listAppConnections($formattedParent); + $response = $appConnectionsServiceClient->listAppConnections($request); /** @var AppConnection $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_locations.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_locations.php index d0b379f37def..b56ae1c1958f 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_locations.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appConnectionsServiceClient->listLocations(); + $response = $appConnectionsServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php index 21a8ba6b2d9c..dc13d13543ea 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_ResolveAppConnections_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsRequest; use Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse\AppConnectionDetails; /** @@ -48,13 +49,15 @@ function resolve_app_connections_sample( // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); + // Prepare the request message. + $request = (new ResolveAppConnectionsRequest()) + ->setParent($formattedParent) + ->setAppConnectorId($formattedAppConnectorId); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appConnectionsServiceClient->resolveAppConnections( - $formattedParent, - $formattedAppConnectorId - ); + $response = $appConnectionsServiceClient->resolveAppConnections($request); /** @var AppConnectionDetails $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/set_iam_policy.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/set_iam_policy.php index 444d0b5ebc2e..c7939e0824b2 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/set_iam_policy.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START beyondcorp_v1_generated_AppConnectionsService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appConnectionsServiceClient->setIamPolicy($resource, $policy); + $response = $appConnectionsServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php index 6b41cf032e2a..a700f9fe57fd 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectionsService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appConnectionsServiceClient->testIamPermissions($resource, $permissions); + $response = $appConnectionsServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/update_app_connection.php b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/update_app_connection.php index adf18d4e77cf..98bf10f2dd9b 100644 --- a/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/update_app_connection.php +++ b/BeyondCorpAppConnections/samples/V1/AppConnectionsServiceClient/update_app_connection.php @@ -28,7 +28,8 @@ use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint; use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Type; -use Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\Client\AppConnectionsServiceClient; +use Google\Cloud\BeyondCorp\AppConnections\V1\UpdateAppConnectionRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -50,7 +51,7 @@ function update_app_connection_sample( // Create a client. $appConnectionsServiceClient = new AppConnectionsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $appConnectionApplicationEndpoint = (new ApplicationEndpoint()) ->setHost($appConnectionApplicationEndpointHost) @@ -59,11 +60,14 @@ function update_app_connection_sample( ->setName($appConnectionName) ->setType($appConnectionType) ->setApplicationEndpoint($appConnectionApplicationEndpoint); + $request = (new UpdateAppConnectionRequest()) + ->setUpdateMask($updateMask) + ->setAppConnection($appConnection); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->updateAppConnection($updateMask, $appConnection); + $response = $appConnectionsServiceClient->updateAppConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/Client/AppConnectionsServiceClient.php b/BeyondCorpAppConnections/src/V1/Client/AppConnectionsServiceClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/Client/AppConnectionsServiceClient.php rename to BeyondCorpAppConnections/src/V1/Client/AppConnectionsServiceClient.php diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/Client/BaseClient/AppConnectionsServiceBaseClient.php b/BeyondCorpAppConnections/src/V1/Client/BaseClient/AppConnectionsServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/Client/BaseClient/AppConnectionsServiceBaseClient.php rename to BeyondCorpAppConnections/src/V1/Client/BaseClient/AppConnectionsServiceBaseClient.php diff --git a/BeyondCorpAppConnections/src/V1/CreateAppConnectionRequest.php b/BeyondCorpAppConnections/src/V1/CreateAppConnectionRequest.php index 324ed4a9dde1..64e7b7c1e32a 100644 --- a/BeyondCorpAppConnections/src/V1/CreateAppConnectionRequest.php +++ b/BeyondCorpAppConnections/src/V1/CreateAppConnectionRequest.php @@ -61,6 +61,28 @@ class CreateAppConnectionRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $parent Required. The resource project name of the AppConnection location using the + * form: `projects/{project_id}/locations/{location_id}` + * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection Required. A BeyondCorp AppConnection resource. + * @param string $appConnectionId Optional. User-settable AppConnection resource ID. + * * Must start with a letter. + * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. + * * Must end with a number or a letter. + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\CreateAppConnectionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection, string $appConnectionId): self + { + return (new self()) + ->setParent($parent) + ->setAppConnection($appConnection) + ->setAppConnectionId($appConnectionId); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/DeleteAppConnectionRequest.php b/BeyondCorpAppConnections/src/V1/DeleteAppConnectionRequest.php index 53968baa6866..c32214d2bd1c 100644 --- a/BeyondCorpAppConnections/src/V1/DeleteAppConnectionRequest.php +++ b/BeyondCorpAppConnections/src/V1/DeleteAppConnectionRequest.php @@ -46,6 +46,21 @@ class DeleteAppConnectionRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. BeyondCorp Connector name using the form: + * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` + * Please see {@see AppConnectionsServiceClient::appConnectionName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\DeleteAppConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/GetAppConnectionRequest.php b/BeyondCorpAppConnections/src/V1/GetAppConnectionRequest.php index 9cddaa58b7a5..10bc77a1d4f1 100644 --- a/BeyondCorpAppConnections/src/V1/GetAppConnectionRequest.php +++ b/BeyondCorpAppConnections/src/V1/GetAppConnectionRequest.php @@ -23,6 +23,21 @@ class GetAppConnectionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. BeyondCorp AppConnection name using the form: + * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` + * Please see {@see AppConnectionsServiceClient::appConnectionName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\GetAppConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/ListAppConnectionsRequest.php b/BeyondCorpAppConnections/src/V1/ListAppConnectionsRequest.php index 0a8b6c8afd4d..ba67e6ebfd44 100644 --- a/BeyondCorpAppConnections/src/V1/ListAppConnectionsRequest.php +++ b/BeyondCorpAppConnections/src/V1/ListAppConnectionsRequest.php @@ -56,6 +56,21 @@ class ListAppConnectionsRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The resource name of the AppConnection location using the form: + * `projects/{project_id}/locations/{location_id}` + * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/ResolveAppConnectionsRequest.php b/BeyondCorpAppConnections/src/V1/ResolveAppConnectionsRequest.php index 41ad987df0c1..ab361cca1d91 100644 --- a/BeyondCorpAppConnections/src/V1/ResolveAppConnectionsRequest.php +++ b/BeyondCorpAppConnections/src/V1/ResolveAppConnectionsRequest.php @@ -49,6 +49,21 @@ class ResolveAppConnectionsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The resource name of the AppConnection location using the form: + * `projects/{project_id}/locations/{location_id}` + * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/UpdateAppConnectionRequest.php b/BeyondCorpAppConnections/src/V1/UpdateAppConnectionRequest.php index eb410fb636d9..05617d25054f 100644 --- a/BeyondCorpAppConnections/src/V1/UpdateAppConnectionRequest.php +++ b/BeyondCorpAppConnections/src/V1/UpdateAppConnectionRequest.php @@ -64,6 +64,28 @@ class UpdateAppConnectionRequest extends \Google\Protobuf\Internal\Message */ private $allow_missing = false; + /** + * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection Required. AppConnection message with updated fields. Only supported fields + * specified in update_mask are updated. + * @param \Google\Protobuf\FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in + * this field. The elements of the repeated paths field may only include these + * fields from [BeyondCorp.AppConnection]: + * * `labels` + * * `display_name` + * * `application_endpoint` + * * `connectors` + * + * @return \Google\Cloud\BeyondCorp\AppConnections\V1\UpdateAppConnectionRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setAppConnection($appConnection) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnections/src/V1/resources/app_connections_service_descriptor_config.php b/BeyondCorpAppConnections/src/V1/resources/app_connections_service_descriptor_config.php index 4ec11ddc9ef5..0efddabe3d31 100644 --- a/BeyondCorpAppConnections/src/V1/resources/app_connections_service_descriptor_config.php +++ b/BeyondCorpAppConnections/src/V1/resources/app_connections_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteAppConnection' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateAppConnection' => [ 'longRunning' => [ @@ -32,6 +50,28 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'app_connection.name', + 'fieldAccessors' => [ + 'getAppConnection', + 'getName', + ], + ], + ], + ], + 'GetAppConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListAppConnections' => [ 'pageStreaming' => [ @@ -42,6 +82,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAppConnections', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ResolveAppConnections' => [ 'pageStreaming' => [ @@ -52,8 +102,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAppConnectionDetails', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -65,17 +135,63 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'appConnection' => 'projects/{project}/locations/{location}/appConnections/{app_connection}', + 'appConnector' => 'projects/{project}/locations/{location}/appConnectors/{app_connector}', + 'appGateway' => 'projects/{project}/locations/{location}/appGateways/{app_gateway}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/Client/AppConnectionsServiceClientTest.php b/BeyondCorpAppConnections/tests/Unit/V1/Client/AppConnectionsServiceClientTest.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/Client/AppConnectionsServiceClientTest.php rename to BeyondCorpAppConnections/tests/Unit/V1/Client/AppConnectionsServiceClientTest.php diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/create_app_connector.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/create_app_connector.php index 8ebe933a49b2..7c3dfa1f4529 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/create_app_connector.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/create_app_connector.php @@ -27,7 +27,8 @@ use Google\ApiCore\OperationResponse; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\CreateAppConnectorRequest; use Google\Rpc\Status; /** @@ -44,16 +45,19 @@ function create_app_connector_sample(string $formattedParent, string $appConnect // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $appConnectorPrincipalInfo = new PrincipalInfo(); $appConnector = (new AppConnector()) ->setName($appConnectorName) ->setPrincipalInfo($appConnectorPrincipalInfo); + $request = (new CreateAppConnectorRequest()) + ->setParent($formattedParent) + ->setAppConnector($appConnector); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->createAppConnector($formattedParent, $appConnector); + $response = $appConnectorsServiceClient->createAppConnector($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/delete_app_connector.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/delete_app_connector.php index 0079ce840a80..55b4c09ec420 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/delete_app_connector.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/delete_app_connector.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_DeleteAppConnector_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\DeleteAppConnectorRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_app_connector_sample(string $formattedName): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = (new DeleteAppConnectorRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->deleteAppConnector($formattedName); + $response = $appConnectorsServiceClient->deleteAppConnector($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_app_connector.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_app_connector.php index 04aea7df5abe..69769d7d5b5f 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_app_connector.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_app_connector.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_GetAppConnector_sync] use Google\ApiCore\ApiException; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\GetAppConnectorRequest; /** * Gets details of a single AppConnector. @@ -39,10 +40,14 @@ function get_app_connector_sample(string $formattedName): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = (new GetAppConnectorRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var AppConnector $response */ - $response = $appConnectorsServiceClient->getAppConnector($formattedName); + $response = $appConnectorsServiceClient->getAppConnector($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_iam_policy.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_iam_policy.php index f347567b3f0d..1097dcd81a59 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_iam_policy.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $appConnectorsServiceClient->getIamPolicy($resource); + $response = $appConnectorsServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_location.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_location.php index 067f5ba17bb5..5943c7c4d8d7 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_location.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $appConnectorsServiceClient->getLocation(); + $response = $appConnectorsServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_app_connectors.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_app_connectors.php index 4aa8cf90e2de..18aa53568a68 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_app_connectors.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_app_connectors.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsRequest; /** * Lists AppConnectors in a given project and location. @@ -40,10 +41,14 @@ function list_app_connectors_sample(string $formattedParent): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = (new ListAppConnectorsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appConnectorsServiceClient->listAppConnectors($formattedParent); + $response = $appConnectorsServiceClient->listAppConnectors($request); /** @var AppConnector $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_locations.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_locations.php index 499d4cdf02d7..d1d9ce37dedc 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_locations.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appConnectorsServiceClient->listLocations(); + $response = $appConnectorsServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/report_status.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/report_status.php index f7db25092e9c..fc566ebf071c 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/report_status.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/report_status.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\ReportStatusRequest; use Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo; use Google\Rpc\Status; @@ -43,14 +44,17 @@ function report_status_sample(string $formattedAppConnector, string $resourceInf // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $resourceInfo = (new ResourceInfo()) ->setId($resourceInfoId); + $request = (new ReportStatusRequest()) + ->setAppConnector($formattedAppConnector) + ->setResourceInfo($resourceInfo); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->reportStatus($formattedAppConnector, $resourceInfo); + $response = $appConnectorsServiceClient->reportStatus($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/set_iam_policy.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/set_iam_policy.php index 3a2278e5479d..780821be06c8 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/set_iam_policy.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START beyondcorp_v1_generated_AppConnectorsService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appConnectorsServiceClient->setIamPolicy($resource, $policy); + $response = $appConnectorsServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php index ec6245eda28a..78f96c10fe71 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppConnectorsService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appConnectorsServiceClient->testIamPermissions($resource, $permissions); + $response = $appConnectorsServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/update_app_connector.php b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/update_app_connector.php index 658aa75b8c82..9ee772214c0f 100644 --- a/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/update_app_connector.php +++ b/BeyondCorpAppConnectors/samples/V1/AppConnectorsServiceClient/update_app_connector.php @@ -27,7 +27,8 @@ use Google\ApiCore\OperationResponse; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector; use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo; -use Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\Client\AppConnectorsServiceClient; +use Google\Cloud\BeyondCorp\AppConnectors\V1\UpdateAppConnectorRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -42,17 +43,20 @@ function update_app_connector_sample(string $appConnectorName): void // Create a client. $appConnectorsServiceClient = new AppConnectorsServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $appConnectorPrincipalInfo = new PrincipalInfo(); $appConnector = (new AppConnector()) ->setName($appConnectorName) ->setPrincipalInfo($appConnectorPrincipalInfo); + $request = (new UpdateAppConnectorRequest()) + ->setUpdateMask($updateMask) + ->setAppConnector($appConnector); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->updateAppConnector($updateMask, $appConnector); + $response = $appConnectorsServiceClient->updateAppConnector($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/Client/AppConnectorsServiceClient.php b/BeyondCorpAppConnectors/src/V1/Client/AppConnectorsServiceClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/Client/AppConnectorsServiceClient.php rename to BeyondCorpAppConnectors/src/V1/Client/AppConnectorsServiceClient.php diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/Client/BaseClient/AppConnectorsServiceBaseClient.php b/BeyondCorpAppConnectors/src/V1/Client/BaseClient/AppConnectorsServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/Client/BaseClient/AppConnectorsServiceBaseClient.php rename to BeyondCorpAppConnectors/src/V1/Client/BaseClient/AppConnectorsServiceBaseClient.php diff --git a/BeyondCorpAppConnectors/src/V1/CreateAppConnectorRequest.php b/BeyondCorpAppConnectors/src/V1/CreateAppConnectorRequest.php index e23e1c81b788..d927f6cb34e3 100644 --- a/BeyondCorpAppConnectors/src/V1/CreateAppConnectorRequest.php +++ b/BeyondCorpAppConnectors/src/V1/CreateAppConnectorRequest.php @@ -61,6 +61,29 @@ class CreateAppConnectorRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $parent Required. The resource project name of the AppConnector location using the + * form: `projects/{project_id}/locations/{location_id}` + * Please see {@see AppConnectorsServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector Required. A BeyondCorp AppConnector resource. + * @param string $appConnectorId Optional. User-settable AppConnector resource ID. + * + * * Must start with a letter. + * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. + * * Must end with a number or a letter. + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\CreateAppConnectorRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector, string $appConnectorId): self + { + return (new self()) + ->setParent($parent) + ->setAppConnector($appConnector) + ->setAppConnectorId($appConnectorId); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/DeleteAppConnectorRequest.php b/BeyondCorpAppConnectors/src/V1/DeleteAppConnectorRequest.php index a19010ce0696..8daff7f552be 100644 --- a/BeyondCorpAppConnectors/src/V1/DeleteAppConnectorRequest.php +++ b/BeyondCorpAppConnectors/src/V1/DeleteAppConnectorRequest.php @@ -46,6 +46,21 @@ class DeleteAppConnectorRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. BeyondCorp AppConnector name using the form: + * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` + * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\DeleteAppConnectorRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/GetAppConnectorRequest.php b/BeyondCorpAppConnectors/src/V1/GetAppConnectorRequest.php index f81f951b06aa..b6e027fb8ff9 100644 --- a/BeyondCorpAppConnectors/src/V1/GetAppConnectorRequest.php +++ b/BeyondCorpAppConnectors/src/V1/GetAppConnectorRequest.php @@ -23,6 +23,21 @@ class GetAppConnectorRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. BeyondCorp AppConnector name using the form: + * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` + * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\GetAppConnectorRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/ListAppConnectorsRequest.php b/BeyondCorpAppConnectors/src/V1/ListAppConnectorsRequest.php index e62b89705ad8..733116c6737e 100644 --- a/BeyondCorpAppConnectors/src/V1/ListAppConnectorsRequest.php +++ b/BeyondCorpAppConnectors/src/V1/ListAppConnectorsRequest.php @@ -56,6 +56,21 @@ class ListAppConnectorsRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The resource name of the AppConnector location using the form: + * `projects/{project_id}/locations/{location_id}` + * Please see {@see AppConnectorsServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/ReportStatusRequest.php b/BeyondCorpAppConnectors/src/V1/ReportStatusRequest.php index d4366cdadf91..e3f04afb0147 100644 --- a/BeyondCorpAppConnectors/src/V1/ReportStatusRequest.php +++ b/BeyondCorpAppConnectors/src/V1/ReportStatusRequest.php @@ -52,6 +52,23 @@ class ReportStatusRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $appConnector Required. BeyondCorp Connector name using the form: + * `projects/{project_id}/locations/{location_id}/connectors/{connector}` + * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resourceInfo Required. Resource info of the connector. + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ReportStatusRequest + * + * @experimental + */ + public static function build(string $appConnector, \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resourceInfo): self + { + return (new self()) + ->setAppConnector($appConnector) + ->setResourceInfo($resourceInfo); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/UpdateAppConnectorRequest.php b/BeyondCorpAppConnectors/src/V1/UpdateAppConnectorRequest.php index 3346274e56a0..c4464ebe1dc4 100644 --- a/BeyondCorpAppConnectors/src/V1/UpdateAppConnectorRequest.php +++ b/BeyondCorpAppConnectors/src/V1/UpdateAppConnectorRequest.php @@ -56,6 +56,26 @@ class UpdateAppConnectorRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector Required. AppConnector message with updated fields. Only supported fields + * specified in update_mask are updated. + * @param \Google\Protobuf\FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in + * this field. The elements of the repeated paths field may only include these + * fields from [BeyondCorp.AppConnector]: + * * `labels` + * * `display_name` + * + * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\UpdateAppConnectorRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setAppConnector($appConnector) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BeyondCorpAppConnectors/src/V1/resources/app_connectors_service_descriptor_config.php b/BeyondCorpAppConnectors/src/V1/resources/app_connectors_service_descriptor_config.php index d04a3c4796d7..2f6d0ac9a2c9 100644 --- a/BeyondCorpAppConnectors/src/V1/resources/app_connectors_service_descriptor_config.php +++ b/BeyondCorpAppConnectors/src/V1/resources/app_connectors_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteAppConnector' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ReportStatus' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'app_connector', + 'fieldAccessors' => [ + 'getAppConnector', + ], + ], + ], ], 'UpdateAppConnector' => [ 'longRunning' => [ @@ -42,6 +69,28 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'app_connector.name', + 'fieldAccessors' => [ + 'getAppConnector', + 'getName', + ], + ], + ], + ], + 'GetAppConnector' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListAppConnectors' => [ 'pageStreaming' => [ @@ -52,8 +101,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAppConnectors', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -65,17 +134,61 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'appConnector' => 'projects/{project}/locations/{location}/appConnectors/{app_connector}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/Client/AppConnectorsServiceClientTest.php b/BeyondCorpAppConnectors/tests/Unit/V1/Client/AppConnectorsServiceClientTest.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/Client/AppConnectorsServiceClientTest.php rename to BeyondCorpAppConnectors/tests/Unit/V1/Client/AppConnectorsServiceClientTest.php diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/create_app_gateway.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/create_app_gateway.php index 1d12cbf420a2..4b72dae2fbf9 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/create_app_gateway.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/create_app_gateway.php @@ -28,7 +28,8 @@ use Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway; use Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\HostType; use Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\Type; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\CreateAppGatewayRequest; use Google\Rpc\Status; /** @@ -51,16 +52,19 @@ function create_app_gateway_sample( // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $appGateway = (new AppGateway()) ->setName($appGatewayName) ->setType($appGatewayType) ->setHostType($appGatewayHostType); + $request = (new CreateAppGatewayRequest()) + ->setParent($formattedParent) + ->setAppGateway($appGateway); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appGatewaysServiceClient->createAppGateway($formattedParent, $appGateway); + $response = $appGatewaysServiceClient->createAppGateway($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php index 2f3bc68ae1c8..a543f2934ce2 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_DeleteAppGateway_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\DeleteAppGatewayRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_app_gateway_sample(string $formattedName): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = (new DeleteAppGatewayRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $appGatewaysServiceClient->deleteAppGateway($formattedName); + $response = $appGatewaysServiceClient->deleteAppGateway($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_app_gateway.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_app_gateway.php index 6ab8035bc5a6..2259c5dede81 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_app_gateway.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_app_gateway.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_GetAppGateway_sync] use Google\ApiCore\ApiException; use Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\GetAppGatewayRequest; /** * Gets details of a single AppGateway. @@ -39,10 +40,14 @@ function get_app_gateway_sample(string $formattedName): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = (new GetAppGatewayRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var AppGateway $response */ - $response = $appGatewaysServiceClient->getAppGateway($formattedName); + $response = $appGatewaysServiceClient->getAppGateway($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_iam_policy.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_iam_policy.php index 0692683c499d..e4182baf1496 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_iam_policy.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $appGatewaysServiceClient->getIamPolicy($resource); + $response = $appGatewaysServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_location.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_location.php index 95d90c2f59df..ee642ec9305d 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_location.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $appGatewaysServiceClient->getLocation(); + $response = $appGatewaysServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_app_gateways.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_app_gateways.php index 4977a31f190c..19e873c5adcf 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_app_gateways.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_app_gateways.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysRequest; /** * Lists AppGateways in a given project and location. @@ -40,10 +41,14 @@ function list_app_gateways_sample(string $formattedParent): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = (new ListAppGatewaysRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appGatewaysServiceClient->listAppGateways($formattedParent); + $response = $appGatewaysServiceClient->listAppGateways($request); /** @var AppGateway $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_locations.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_locations.php index c7c32844cbf3..5cc04ee4f650 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_locations.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $appGatewaysServiceClient->listLocations(); + $response = $appGatewaysServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/set_iam_policy.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/set_iam_policy.php index 0203e41aa6ec..064ad3404c36 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/set_iam_policy.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START beyondcorp_v1_generated_AppGatewaysService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appGatewaysServiceClient->setIamPolicy($resource, $policy); + $response = $appGatewaysServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php index 74a280917a53..579149af0387 100644 --- a/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php +++ b/BeyondCorpAppGateways/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_AppGatewaysService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewaysServiceClient; +use Google\Cloud\BeyondCorp\AppGateways\V1\Client\AppGatewaysServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $appGatewaysServiceClient = new AppGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $appGatewaysServiceClient->testIamPermissions($resource, $permissions); + $response = $appGatewaysServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/Client/AppGatewaysServiceClient.php b/BeyondCorpAppGateways/src/V1/Client/AppGatewaysServiceClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/Client/AppGatewaysServiceClient.php rename to BeyondCorpAppGateways/src/V1/Client/AppGatewaysServiceClient.php diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/Client/BaseClient/AppGatewaysServiceBaseClient.php b/BeyondCorpAppGateways/src/V1/Client/BaseClient/AppGatewaysServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/Client/BaseClient/AppGatewaysServiceBaseClient.php rename to BeyondCorpAppGateways/src/V1/Client/BaseClient/AppGatewaysServiceBaseClient.php diff --git a/BeyondCorpAppGateways/src/V1/CreateAppGatewayRequest.php b/BeyondCorpAppGateways/src/V1/CreateAppGatewayRequest.php index 07bdd12880d9..7cdb4f5bb709 100644 --- a/BeyondCorpAppGateways/src/V1/CreateAppGatewayRequest.php +++ b/BeyondCorpAppGateways/src/V1/CreateAppGatewayRequest.php @@ -61,6 +61,28 @@ class CreateAppGatewayRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $parent Required. The resource project name of the AppGateway location using the + * form: `projects/{project_id}/locations/{location_id}` + * Please see {@see AppGatewaysServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $appGateway Required. A BeyondCorp AppGateway resource. + * @param string $appGatewayId Optional. User-settable AppGateway resource ID. + * * Must start with a letter. + * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. + * * Must end with a number or a letter. + * + * @return \Google\Cloud\BeyondCorp\AppGateways\V1\CreateAppGatewayRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $appGateway, string $appGatewayId): self + { + return (new self()) + ->setParent($parent) + ->setAppGateway($appGateway) + ->setAppGatewayId($appGatewayId); + } + /** * Constructor. * diff --git a/BeyondCorpAppGateways/src/V1/DeleteAppGatewayRequest.php b/BeyondCorpAppGateways/src/V1/DeleteAppGatewayRequest.php index bb38ea8520ef..12f8ed7be02e 100644 --- a/BeyondCorpAppGateways/src/V1/DeleteAppGatewayRequest.php +++ b/BeyondCorpAppGateways/src/V1/DeleteAppGatewayRequest.php @@ -46,6 +46,21 @@ class DeleteAppGatewayRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. BeyondCorp AppGateway name using the form: + * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` + * Please see {@see AppGatewaysServiceClient::appGatewayName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppGateways\V1\DeleteAppGatewayRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppGateways/src/V1/GetAppGatewayRequest.php b/BeyondCorpAppGateways/src/V1/GetAppGatewayRequest.php index 20b715f77585..829a72acb3cb 100644 --- a/BeyondCorpAppGateways/src/V1/GetAppGatewayRequest.php +++ b/BeyondCorpAppGateways/src/V1/GetAppGatewayRequest.php @@ -23,6 +23,21 @@ class GetAppGatewayRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. BeyondCorp AppGateway name using the form: + * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` + * Please see {@see AppGatewaysServiceClient::appGatewayName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppGateways\V1\GetAppGatewayRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpAppGateways/src/V1/ListAppGatewaysRequest.php b/BeyondCorpAppGateways/src/V1/ListAppGatewaysRequest.php index 8c7bcbd11493..751049db5960 100644 --- a/BeyondCorpAppGateways/src/V1/ListAppGatewaysRequest.php +++ b/BeyondCorpAppGateways/src/V1/ListAppGatewaysRequest.php @@ -56,6 +56,21 @@ class ListAppGatewaysRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The resource name of the AppGateway location using the form: + * `projects/{project_id}/locations/{location_id}` + * Please see {@see AppGatewaysServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpAppGateways/src/V1/resources/app_gateways_service_descriptor_config.php b/BeyondCorpAppGateways/src/V1/resources/app_gateways_service_descriptor_config.php index f49bc450817d..270c9a8fe5da 100644 --- a/BeyondCorpAppGateways/src/V1/resources/app_gateways_service_descriptor_config.php +++ b/BeyondCorpAppGateways/src/V1/resources/app_gateways_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteAppGateway' => [ 'longRunning' => [ @@ -22,6 +31,27 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetAppGateway' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListAppGateways' => [ 'pageStreaming' => [ @@ -32,8 +62,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAppGateways', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -45,17 +95,61 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'appGateway' => 'projects/{project}/locations/{location}/appGateways/{app_gateway}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/Client/AppGatewaysServiceClientTest.php b/BeyondCorpAppGateways/tests/Unit/V1/Client/AppGatewaysServiceClientTest.php similarity index 100% rename from owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/Client/AppGatewaysServiceClientTest.php rename to BeyondCorpAppGateways/tests/Unit/V1/Client/AppGatewaysServiceClientTest.php diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php index 59c73322f006..bf80bd33f586 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php @@ -28,7 +28,8 @@ use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\CreateClientConnectorServiceRequest; use Google\Rpc\Status; /** @@ -45,21 +46,21 @@ function create_client_connector_service_sample( // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $clientConnectorServiceIngress = new Ingress(); $clientConnectorServiceEgress = new Egress(); $clientConnectorService = (new ClientConnectorService()) ->setName($clientConnectorServiceName) ->setIngress($clientConnectorServiceIngress) ->setEgress($clientConnectorServiceEgress); + $request = (new CreateClientConnectorServiceRequest()) + ->setParent($formattedParent) + ->setClientConnectorService($clientConnectorService); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->createClientConnectorService( - $formattedParent, - $clientConnectorService - ); + $response = $clientConnectorServicesServiceClient->createClientConnectorService($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php index 9d51c0a06711..df7d34e8d718 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_DeleteClientConnectorService_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\DeleteClientConnectorServiceRequest; use Google\Rpc\Status; /** @@ -39,10 +40,14 @@ function delete_client_connector_service_sample(string $formattedName): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = (new DeleteClientConnectorServiceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->deleteClientConnectorService($formattedName); + $response = $clientConnectorServicesServiceClient->deleteClientConnectorService($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php index 97d61cf288b4..7f2adcc6cb9d 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_GetClientConnectorService_sync] use Google\ApiCore\ApiException; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\GetClientConnectorServiceRequest; /** * Gets details of a single ClientConnectorService. @@ -38,10 +39,14 @@ function get_client_connector_service_sample(string $formattedName): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = (new GetClientConnectorServiceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ClientConnectorService $response */ - $response = $clientConnectorServicesServiceClient->getClientConnectorService($formattedName); + $response = $clientConnectorServicesServiceClient->getClientConnectorService($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php index 995a64383848..488644ac6b2e 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $clientConnectorServicesServiceClient->getIamPolicy($resource); + $response = $clientConnectorServicesServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_location.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_location.php index 213d17e0dae1..7b7e2d64f08b 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_location.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $clientConnectorServicesServiceClient->getLocation(); + $response = $clientConnectorServicesServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php index 20fd1faaa2bf..8ac8cf783ffa 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesRequest; /** * Lists ClientConnectorServices in a given project and location. @@ -39,10 +40,14 @@ function list_client_connector_services_sample(string $formattedParent): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = (new ListClientConnectorServicesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $clientConnectorServicesServiceClient->listClientConnectorServices($formattedParent); + $response = $clientConnectorServicesServiceClient->listClientConnectorServices($request); /** @var ClientConnectorService $element */ foreach ($response as $element) { diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_locations.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_locations.php index 728283c2fa02..8107e78c6720 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_locations.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $clientConnectorServicesServiceClient->listLocations(); + $response = $clientConnectorServicesServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php index ff24cc887023..559ce0e96c8f 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $clientConnectorServicesServiceClient->setIamPolicy($resource, $policy); + $response = $clientConnectorServicesServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php index fb34e335df9b..c0f8e80df712 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientConnectorServicesService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $clientConnectorServicesServiceClient->testIamPermissions($resource, $permissions); + $response = $clientConnectorServicesServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php index aed552bf47d4..96ec12eb14b5 100644 --- a/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php +++ b/BeyondCorpClientConnectorServices/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php @@ -28,7 +28,8 @@ use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress; use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress; -use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\Client\ClientConnectorServicesServiceClient; +use Google\Cloud\BeyondCorp\ClientConnectorServices\V1\UpdateClientConnectorServiceRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -42,7 +43,7 @@ function update_client_connector_service_sample(string $clientConnectorServiceNa // Create a client. $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $clientConnectorServiceIngress = new Ingress(); $clientConnectorServiceEgress = new Egress(); @@ -50,14 +51,14 @@ function update_client_connector_service_sample(string $clientConnectorServiceNa ->setName($clientConnectorServiceName) ->setIngress($clientConnectorServiceIngress) ->setEgress($clientConnectorServiceEgress); + $request = (new UpdateClientConnectorServiceRequest()) + ->setUpdateMask($updateMask) + ->setClientConnectorService($clientConnectorService); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->updateClientConnectorService( - $updateMask, - $clientConnectorService - ); + $response = $clientConnectorServicesServiceClient->updateClientConnectorService($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/Client/BaseClient/ClientConnectorServicesServiceBaseClient.php b/BeyondCorpClientConnectorServices/src/V1/Client/BaseClient/ClientConnectorServicesServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/Client/BaseClient/ClientConnectorServicesServiceBaseClient.php rename to BeyondCorpClientConnectorServices/src/V1/Client/BaseClient/ClientConnectorServicesServiceBaseClient.php diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/Client/ClientConnectorServicesServiceClient.php b/BeyondCorpClientConnectorServices/src/V1/Client/ClientConnectorServicesServiceClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/Client/ClientConnectorServicesServiceClient.php rename to BeyondCorpClientConnectorServices/src/V1/Client/ClientConnectorServicesServiceClient.php diff --git a/BeyondCorpClientConnectorServices/src/V1/CreateClientConnectorServiceRequest.php b/BeyondCorpClientConnectorServices/src/V1/CreateClientConnectorServiceRequest.php index 07f9c76ffc38..d3a9baeac8ba 100644 --- a/BeyondCorpClientConnectorServices/src/V1/CreateClientConnectorServiceRequest.php +++ b/BeyondCorpClientConnectorServices/src/V1/CreateClientConnectorServiceRequest.php @@ -62,6 +62,30 @@ class CreateClientConnectorServiceRequest extends \Google\Protobuf\Internal\Mess */ private $validate_only = false; + /** + * @param string $parent Required. Value for parent. Please see + * {@see ClientConnectorServicesServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService Required. The resource being created. + * @param string $clientConnectorServiceId Optional. User-settable client connector service resource ID. + * * Must start with a letter. + * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. + * * Must end with a number or a letter. + * + * A random system generated name will be assigned + * if not specified by the user. + * + * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\CreateClientConnectorServiceRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService, string $clientConnectorServiceId): self + { + return (new self()) + ->setParent($parent) + ->setClientConnectorService($clientConnectorService) + ->setClientConnectorServiceId($clientConnectorServiceId); + } + /** * Constructor. * diff --git a/BeyondCorpClientConnectorServices/src/V1/DeleteClientConnectorServiceRequest.php b/BeyondCorpClientConnectorServices/src/V1/DeleteClientConnectorServiceRequest.php index 017759dcad65..fc6657258aaa 100644 --- a/BeyondCorpClientConnectorServices/src/V1/DeleteClientConnectorServiceRequest.php +++ b/BeyondCorpClientConnectorServices/src/V1/DeleteClientConnectorServiceRequest.php @@ -45,6 +45,20 @@ class DeleteClientConnectorServiceRequest extends \Google\Protobuf\Internal\Mess */ private $validate_only = false; + /** + * @param string $name Required. Name of the resource. Please see + * {@see ClientConnectorServicesServiceClient::clientConnectorServiceName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\DeleteClientConnectorServiceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpClientConnectorServices/src/V1/GetClientConnectorServiceRequest.php b/BeyondCorpClientConnectorServices/src/V1/GetClientConnectorServiceRequest.php index 9f5e66ef8ef1..26a116ab1704 100644 --- a/BeyondCorpClientConnectorServices/src/V1/GetClientConnectorServiceRequest.php +++ b/BeyondCorpClientConnectorServices/src/V1/GetClientConnectorServiceRequest.php @@ -22,6 +22,20 @@ class GetClientConnectorServiceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource. Please see + * {@see ClientConnectorServicesServiceClient::clientConnectorServiceName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\GetClientConnectorServiceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpClientConnectorServices/src/V1/ListClientConnectorServicesRequest.php b/BeyondCorpClientConnectorServices/src/V1/ListClientConnectorServicesRequest.php index 0cc0e0f3e005..5710d7889096 100644 --- a/BeyondCorpClientConnectorServices/src/V1/ListClientConnectorServicesRequest.php +++ b/BeyondCorpClientConnectorServices/src/V1/ListClientConnectorServicesRequest.php @@ -47,6 +47,20 @@ class ListClientConnectorServicesRequest extends \Google\Protobuf\Internal\Messa */ private $order_by = ''; + /** + * @param string $parent Required. Parent value for ListClientConnectorServicesRequest. Please see + * {@see ClientConnectorServicesServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpClientConnectorServices/src/V1/UpdateClientConnectorServiceRequest.php b/BeyondCorpClientConnectorServices/src/V1/UpdateClientConnectorServiceRequest.php index 39853b3178a4..faf952ce4900 100644 --- a/BeyondCorpClientConnectorServices/src/V1/UpdateClientConnectorServiceRequest.php +++ b/BeyondCorpClientConnectorServices/src/V1/UpdateClientConnectorServiceRequest.php @@ -62,6 +62,27 @@ class UpdateClientConnectorServiceRequest extends \Google\Protobuf\Internal\Mess */ private $allow_missing = false; + /** + * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService Required. The resource being updated. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * ClientConnectorService resource by the update. + * The fields specified in the update_mask are relative to the resource, not + * the full request. A field will be overwritten if it is in the mask. If the + * user does not provide a mask then all fields will be overwritten. + * + * Mutable fields: display_name. + * + * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\UpdateClientConnectorServiceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setClientConnectorService($clientConnectorService) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BeyondCorpClientConnectorServices/src/V1/resources/client_connector_services_service_descriptor_config.php b/BeyondCorpClientConnectorServices/src/V1/resources/client_connector_services_service_descriptor_config.php index b30050512aa7..593d5772ad92 100644 --- a/BeyondCorpClientConnectorServices/src/V1/resources/client_connector_services_service_descriptor_config.php +++ b/BeyondCorpClientConnectorServices/src/V1/resources/client_connector_services_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteClientConnectorService' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateClientConnectorService' => [ 'longRunning' => [ @@ -32,6 +50,28 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'client_connector_service.name', + 'fieldAccessors' => [ + 'getClientConnectorService', + 'getName', + ], + ], + ], + ], + 'GetClientConnectorService' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListClientConnectorServices' => [ 'pageStreaming' => [ @@ -42,8 +82,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getClientConnectorServices', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -55,17 +115,61 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'clientConnectorService' => 'projects/{project}/locations/{location}/clientConnectorServices/{client_connector_service}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/Client/ClientConnectorServicesServiceClientTest.php b/BeyondCorpClientConnectorServices/tests/Unit/V1/Client/ClientConnectorServicesServiceClientTest.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/Client/ClientConnectorServicesServiceClientTest.php rename to BeyondCorpClientConnectorServices/tests/Unit/V1/Client/ClientConnectorServicesServiceClientTest.php diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php index 576ea4992421..cb7685453f53 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\CreateClientGatewayRequest; use Google\Rpc\Status; /** @@ -41,14 +42,17 @@ function create_client_gateway_sample(string $formattedParent, string $clientGat // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $clientGateway = (new ClientGateway()) ->setName($clientGatewayName); + $request = (new CreateClientGatewayRequest()) + ->setParent($formattedParent) + ->setClientGateway($clientGateway); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $clientGatewaysServiceClient->createClientGateway($formattedParent, $clientGateway); + $response = $clientGatewaysServiceClient->createClientGateway($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php index fcd5ceae7543..15e560c4d6b9 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_DeleteClientGateway_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\DeleteClientGatewayRequest; use Google\Rpc\Status; /** @@ -39,10 +40,14 @@ function delete_client_gateway_sample(string $formattedName): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = (new DeleteClientGatewayRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $clientGatewaysServiceClient->deleteClientGateway($formattedName); + $response = $clientGatewaysServiceClient->deleteClientGateway($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php index 62fb897e7ab5..7cb8f2f2c9dd 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_GetClientGateway_sync] use Google\ApiCore\ApiException; use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\GetClientGatewayRequest; /** * Gets details of a single ClientGateway. @@ -38,10 +39,14 @@ function get_client_gateway_sample(string $formattedName): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = (new GetClientGatewayRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var ClientGateway $response */ - $response = $clientGatewaysServiceClient->getClientGateway($formattedName); + $response = $clientGatewaysServiceClient->getClientGateway($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php index 3bde499c3b21..0626d899b1cf 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $clientGatewaysServiceClient->getIamPolicy($resource); + $response = $clientGatewaysServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_location.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_location.php index 0bd772c7fd31..616db7d03c31 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_location.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $clientGatewaysServiceClient->getLocation(); + $response = $clientGatewaysServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php index fa48f143948f..ec65dca4daba 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysRequest; /** * Lists ClientGateways in a given project and location. @@ -39,10 +40,14 @@ function list_client_gateways_sample(string $formattedParent): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = (new ListClientGatewaysRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $clientGatewaysServiceClient->listClientGateways($formattedParent); + $response = $clientGatewaysServiceClient->listClientGateways($request); /** @var ClientGateway $element */ foreach ($response as $element) { diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_locations.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_locations.php index 443ad77ea4d2..2d325c7d13e1 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_locations.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $clientGatewaysServiceClient->listLocations(); + $response = $clientGatewaysServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php index c03023366361..70d3d84322a8 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $clientGatewaysServiceClient->setIamPolicy($resource, $policy); + $response = $clientGatewaysServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php index 193ca7d827f8..a05775eebcb8 100644 --- a/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php +++ b/BeyondCorpClientGateways/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START beyondcorp_v1_generated_ClientGatewaysService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewaysServiceClient; +use Google\Cloud\BeyondCorp\ClientGateways\V1\Client\ClientGatewaysServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $clientGatewaysServiceClient->testIamPermissions($resource, $permissions); + $response = $clientGatewaysServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/Client/BaseClient/ClientGatewaysServiceBaseClient.php b/BeyondCorpClientGateways/src/V1/Client/BaseClient/ClientGatewaysServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/Client/BaseClient/ClientGatewaysServiceBaseClient.php rename to BeyondCorpClientGateways/src/V1/Client/BaseClient/ClientGatewaysServiceBaseClient.php diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/Client/ClientGatewaysServiceClient.php b/BeyondCorpClientGateways/src/V1/Client/ClientGatewaysServiceClient.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/Client/ClientGatewaysServiceClient.php rename to BeyondCorpClientGateways/src/V1/Client/ClientGatewaysServiceClient.php diff --git a/BeyondCorpClientGateways/src/V1/CreateClientGatewayRequest.php b/BeyondCorpClientGateways/src/V1/CreateClientGatewayRequest.php index a2fabfac8df7..8640495ebaa2 100644 --- a/BeyondCorpClientGateways/src/V1/CreateClientGatewayRequest.php +++ b/BeyondCorpClientGateways/src/V1/CreateClientGatewayRequest.php @@ -60,6 +60,27 @@ class CreateClientGatewayRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $parent Required. Value for parent. Please see + * {@see ClientGatewaysServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $clientGateway Required. The resource being created. + * @param string $clientGatewayId Optional. User-settable client gateway resource ID. + * * Must start with a letter. + * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. + * * Must end with a number or a letter. + * + * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\CreateClientGatewayRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $clientGateway, string $clientGatewayId): self + { + return (new self()) + ->setParent($parent) + ->setClientGateway($clientGateway) + ->setClientGatewayId($clientGatewayId); + } + /** * Constructor. * diff --git a/BeyondCorpClientGateways/src/V1/DeleteClientGatewayRequest.php b/BeyondCorpClientGateways/src/V1/DeleteClientGatewayRequest.php index d27645ecd8f8..c04514891435 100644 --- a/BeyondCorpClientGateways/src/V1/DeleteClientGatewayRequest.php +++ b/BeyondCorpClientGateways/src/V1/DeleteClientGatewayRequest.php @@ -45,6 +45,20 @@ class DeleteClientGatewayRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. Name of the resource + * Please see {@see ClientGatewaysServiceClient::clientGatewayName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\DeleteClientGatewayRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpClientGateways/src/V1/GetClientGatewayRequest.php b/BeyondCorpClientGateways/src/V1/GetClientGatewayRequest.php index 60b21245bda8..3c30cfa9ba60 100644 --- a/BeyondCorpClientGateways/src/V1/GetClientGatewayRequest.php +++ b/BeyondCorpClientGateways/src/V1/GetClientGatewayRequest.php @@ -22,6 +22,20 @@ class GetClientGatewayRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the resource + * Please see {@see ClientGatewaysServiceClient::clientGatewayName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\GetClientGatewayRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BeyondCorpClientGateways/src/V1/ListClientGatewaysRequest.php b/BeyondCorpClientGateways/src/V1/ListClientGatewaysRequest.php index 54a79d59b667..4ebfc6b5de23 100644 --- a/BeyondCorpClientGateways/src/V1/ListClientGatewaysRequest.php +++ b/BeyondCorpClientGateways/src/V1/ListClientGatewaysRequest.php @@ -47,6 +47,20 @@ class ListClientGatewaysRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. Parent value for ListClientGatewaysRequest. Please see + * {@see ClientGatewaysServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BeyondCorpClientGateways/src/V1/resources/client_gateways_service_descriptor_config.php b/BeyondCorpClientGateways/src/V1/resources/client_gateways_service_descriptor_config.php index 4e071f167f70..053175b674ef 100644 --- a/BeyondCorpClientGateways/src/V1/resources/client_gateways_service_descriptor_config.php +++ b/BeyondCorpClientGateways/src/V1/resources/client_gateways_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteClientGateway' => [ 'longRunning' => [ @@ -22,6 +31,27 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetClientGateway' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListClientGateways' => [ 'pageStreaming' => [ @@ -32,8 +62,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getClientGateways', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -45,17 +95,61 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'clientGateway' => 'projects/{project}/locations/{location}/clientGateways/{client_gateway}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/Client/ClientGatewaysServiceClientTest.php b/BeyondCorpClientGateways/tests/Unit/V1/Client/ClientGatewaysServiceClientTest.php similarity index 100% rename from owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/Client/ClientGatewaysServiceClientTest.php rename to BeyondCorpClientGateways/tests/Unit/V1/Client/ClientGatewaysServiceClientTest.php diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php index a83ac1984b1a..42b07979f897 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_CreateDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\CreateDataExchangeRequest; use Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange; /** @@ -52,18 +53,18 @@ function create_data_exchange_sample( // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dataExchange = (new DataExchange()) ->setDisplayName($dataExchangeDisplayName); + $request = (new CreateDataExchangeRequest()) + ->setParent($formattedParent) + ->setDataExchangeId($dataExchangeId) + ->setDataExchange($dataExchange); // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->createDataExchange( - $formattedParent, - $dataExchangeId, - $dataExchange - ); + $response = $analyticsHubServiceClient->createDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_listing.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_listing.php index daa592f40bd3..ff83f1462ce5 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_listing.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/create_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_CreateListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\CreateListingRequest; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource; @@ -53,16 +54,20 @@ function create_listing_sample( // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $listingBigqueryDataset = new BigQueryDatasetSource(); $listing = (new Listing()) ->setBigqueryDataset($listingBigqueryDataset) ->setDisplayName($listingDisplayName); + $request = (new CreateListingRequest()) + ->setParent($formattedParent) + ->setListingId($listingId) + ->setListing($listing); // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->createListing($formattedParent, $listingId, $listing); + $response = $analyticsHubServiceClient->createListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php index 4b50c01c5077..468aeef96c68 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_DeleteDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteDataExchangeRequest; /** * Deletes an existing data exchange. @@ -38,9 +39,13 @@ function delete_data_exchange_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new DeleteDataExchangeRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $analyticsHubServiceClient->deleteDataExchange($formattedName); + $analyticsHubServiceClient->deleteDataExchange($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_listing.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_listing.php index 7c23a646cfa9..6d8555d76c19 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_listing.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/delete_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_DeleteListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteListingRequest; /** * Deletes a listing. @@ -38,9 +39,13 @@ function delete_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new DeleteListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $analyticsHubServiceClient->deleteListing($formattedName); + $analyticsHubServiceClient->deleteListing($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php index 8613e888cf4e..8f10086ee2ef 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php @@ -24,8 +24,9 @@ // [START analyticshub_v1_generated_AnalyticsHubService_GetDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange; +use Google\Cloud\BigQuery\AnalyticsHub\V1\GetDataExchangeRequest; /** * Gets the details of a data exchange. @@ -39,10 +40,14 @@ function get_data_exchange_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetDataExchangeRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->getDataExchange($formattedName); + $response = $analyticsHubServiceClient->getDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php index f4b8278a5308..80c290c01d3a 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -38,10 +39,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $analyticsHubServiceClient->getIamPolicy($resource); + $response = $analyticsHubServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_listing.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_listing.php index 59977710acba..b971b326e415 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_listing.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/get_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_GetListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\GetListingRequest; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing; /** @@ -39,10 +40,14 @@ function get_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->getListing($formattedName); + $response = $analyticsHubServiceClient->getListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php index c35ab9001da8..9b24b958f637 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php @@ -25,8 +25,9 @@ // [START analyticshub_v1_generated_AnalyticsHubService_ListDataExchanges_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange; +use Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesRequest; /** * Lists all data exchanges in a given project and location. @@ -40,10 +41,14 @@ function list_data_exchanges_sample(string $formattedParent): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListDataExchangesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listDataExchanges($formattedParent); + $response = $analyticsHubServiceClient->listDataExchanges($request); /** @var DataExchange $element */ foreach ($response as $element) { diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_listings.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_listings.php index 44e64a247054..52dcf7c162b4 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_listings.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_listings.php @@ -25,7 +25,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_ListListings_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsRequest; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing; /** @@ -40,10 +41,14 @@ function list_listings_sample(string $formattedParent): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListListingsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listListings($formattedParent); + $response = $analyticsHubServiceClient->listListings($request); /** @var Listing $element */ foreach ($response as $element) { diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php index 03a255ae5e27..1d83c83d207e 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php @@ -25,8 +25,9 @@ // [START analyticshub_v1_generated_AnalyticsHubService_ListOrgDataExchanges_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange; +use Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesRequest; /** * Lists all data exchanges from projects in a given organization and @@ -40,10 +41,14 @@ function list_org_data_exchanges_sample(string $organization): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListOrgDataExchangesRequest()) + ->setOrganization($organization); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listOrgDataExchanges($organization); + $response = $analyticsHubServiceClient->listOrgDataExchanges($request); /** @var DataExchange $element */ foreach ($response as $element) { diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php index 2d62a068d065..06c03c656a50 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START analyticshub_v1_generated_AnalyticsHubService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the IAM policy. @@ -38,13 +39,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $analyticsHubServiceClient->setIamPolicy($resource, $policy); + $response = $analyticsHubServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php index fea6a00194db..26e5c3fe2c53 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_SubscribeListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingRequest; use Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingResponse; /** @@ -44,10 +45,14 @@ function subscribe_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new SubscribeListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var SubscribeListingResponse $response */ - $response = $analyticsHubServiceClient->subscribeListing($formattedName); + $response = $analyticsHubServiceClient->subscribeListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php index 6c052f5a8655..7df1d9215d93 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START analyticshub_v1_generated_AnalyticsHubService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -42,13 +43,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $analyticsHubServiceClient->testIamPermissions($resource, $permissions); + $response = $analyticsHubServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php index 8b1716a12e53..b35ba5907cbd 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php @@ -24,8 +24,9 @@ // [START analyticshub_v1_generated_AnalyticsHubService_UpdateDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange; +use Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateDataExchangeRequest; use Google\Protobuf\FieldMask; /** @@ -42,15 +43,18 @@ function update_data_exchange_sample(string $dataExchangeDisplayName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $dataExchange = (new DataExchange()) ->setDisplayName($dataExchangeDisplayName); + $request = (new UpdateDataExchangeRequest()) + ->setUpdateMask($updateMask) + ->setDataExchange($dataExchange); // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->updateDataExchange($updateMask, $dataExchange); + $response = $analyticsHubServiceClient->updateDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_listing.php b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_listing.php index 2baa58eb8089..a37cfdc1f91a 100644 --- a/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_listing.php +++ b/BigQueryAnalyticsHub/samples/V1/AnalyticsHubServiceClient/update_listing.php @@ -24,9 +24,10 @@ // [START analyticshub_v1_generated_AnalyticsHubService_UpdateListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\AnalyticsHub\V1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\AnalyticsHub\V1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing; use Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource; +use Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateListingRequest; use Google\Protobuf\FieldMask; /** @@ -43,17 +44,20 @@ function update_listing_sample(string $listingDisplayName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $listingBigqueryDataset = new BigQueryDatasetSource(); $listing = (new Listing()) ->setBigqueryDataset($listingBigqueryDataset) ->setDisplayName($listingDisplayName); + $request = (new UpdateListingRequest()) + ->setUpdateMask($updateMask) + ->setListing($listing); // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->updateListing($updateMask, $listing); + $response = $analyticsHubServiceClient->updateListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/Client/AnalyticsHubServiceClient.php b/BigQueryAnalyticsHub/src/V1/Client/AnalyticsHubServiceClient.php similarity index 100% rename from owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/Client/AnalyticsHubServiceClient.php rename to BigQueryAnalyticsHub/src/V1/Client/AnalyticsHubServiceClient.php diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/Client/BaseClient/AnalyticsHubServiceBaseClient.php b/BigQueryAnalyticsHub/src/V1/Client/BaseClient/AnalyticsHubServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/Client/BaseClient/AnalyticsHubServiceBaseClient.php rename to BigQueryAnalyticsHub/src/V1/Client/BaseClient/AnalyticsHubServiceBaseClient.php diff --git a/BigQueryAnalyticsHub/src/V1/CreateDataExchangeRequest.php b/BigQueryAnalyticsHub/src/V1/CreateDataExchangeRequest.php index 4f51f1b4aa16..38bf78819841 100644 --- a/BigQueryAnalyticsHub/src/V1/CreateDataExchangeRequest.php +++ b/BigQueryAnalyticsHub/src/V1/CreateDataExchangeRequest.php @@ -39,6 +39,23 @@ class CreateDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $data_exchange = null; + /** + * @param string $parent Required. The parent resource path of the data exchange. + * e.g. `projects/myproject/locations/US`. Please see + * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange Required. The data exchange to create. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateDataExchangeRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange): self + { + return (new self()) + ->setParent($parent) + ->setDataExchange($dataExchange); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/CreateListingRequest.php b/BigQueryAnalyticsHub/src/V1/CreateListingRequest.php index 365c5351a9a7..cc31064d34d0 100644 --- a/BigQueryAnalyticsHub/src/V1/CreateListingRequest.php +++ b/BigQueryAnalyticsHub/src/V1/CreateListingRequest.php @@ -39,6 +39,23 @@ class CreateListingRequest extends \Google\Protobuf\Internal\Message */ private $listing = null; + /** + * @param string $parent Required. The parent resource path of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing Required. The listing to create. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateListingRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing): self + { + return (new self()) + ->setParent($parent) + ->setListing($listing); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/DeleteDataExchangeRequest.php b/BigQueryAnalyticsHub/src/V1/DeleteDataExchangeRequest.php index 13f27d9f4119..645a5cdf454c 100644 --- a/BigQueryAnalyticsHub/src/V1/DeleteDataExchangeRequest.php +++ b/BigQueryAnalyticsHub/src/V1/DeleteDataExchangeRequest.php @@ -23,6 +23,21 @@ class DeleteDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The full name of the data exchange resource that you want to delete. + * For example, `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteDataExchangeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/DeleteListingRequest.php b/BigQueryAnalyticsHub/src/V1/DeleteListingRequest.php index 3277cbf12b06..007377c6cba8 100644 --- a/BigQueryAnalyticsHub/src/V1/DeleteListingRequest.php +++ b/BigQueryAnalyticsHub/src/V1/DeleteListingRequest.php @@ -23,6 +23,21 @@ class DeleteListingRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Resource name of the listing to delete. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/GetDataExchangeRequest.php b/BigQueryAnalyticsHub/src/V1/GetDataExchangeRequest.php index 8c77999f419a..4214a434e4a7 100644 --- a/BigQueryAnalyticsHub/src/V1/GetDataExchangeRequest.php +++ b/BigQueryAnalyticsHub/src/V1/GetDataExchangeRequest.php @@ -23,6 +23,21 @@ class GetDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the data exchange. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\GetDataExchangeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/GetListingRequest.php b/BigQueryAnalyticsHub/src/V1/GetListingRequest.php index 918563852d9a..f98730bac8cc 100644 --- a/BigQueryAnalyticsHub/src/V1/GetListingRequest.php +++ b/BigQueryAnalyticsHub/src/V1/GetListingRequest.php @@ -23,6 +23,21 @@ class GetListingRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\GetListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/ListDataExchangesRequest.php b/BigQueryAnalyticsHub/src/V1/ListDataExchangesRequest.php index 49ef88f753c5..7d079cef61ed 100644 --- a/BigQueryAnalyticsHub/src/V1/ListDataExchangesRequest.php +++ b/BigQueryAnalyticsHub/src/V1/ListDataExchangesRequest.php @@ -37,6 +37,21 @@ class ListDataExchangesRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The parent resource path of the data exchanges. + * e.g. `projects/myproject/locations/US`. Please see + * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/ListListingsRequest.php b/BigQueryAnalyticsHub/src/V1/ListListingsRequest.php index 13830a6cd124..9cb0235be004 100644 --- a/BigQueryAnalyticsHub/src/V1/ListListingsRequest.php +++ b/BigQueryAnalyticsHub/src/V1/ListListingsRequest.php @@ -37,6 +37,21 @@ class ListListingsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The parent resource path of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/ListOrgDataExchangesRequest.php b/BigQueryAnalyticsHub/src/V1/ListOrgDataExchangesRequest.php index 7cf46e10e06f..5a501eae37fc 100644 --- a/BigQueryAnalyticsHub/src/V1/ListOrgDataExchangesRequest.php +++ b/BigQueryAnalyticsHub/src/V1/ListOrgDataExchangesRequest.php @@ -38,6 +38,20 @@ class ListOrgDataExchangesRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $organization Required. The organization resource path of the projects containing DataExchanges. + * e.g. `organizations/myorg/locations/US`. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesRequest + * + * @experimental + */ + public static function build(string $organization): self + { + return (new self()) + ->setOrganization($organization); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/SubscribeListingRequest.php b/BigQueryAnalyticsHub/src/V1/SubscribeListingRequest.php index dd5ecc9d7411..7fd3af2309c3 100644 --- a/BigQueryAnalyticsHub/src/V1/SubscribeListingRequest.php +++ b/BigQueryAnalyticsHub/src/V1/SubscribeListingRequest.php @@ -24,6 +24,21 @@ class SubscribeListingRequest extends \Google\Protobuf\Internal\Message private $name = ''; protected $destination; + /** + * @param string $name Required. Resource name of the listing that you want to subscribe to. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/UpdateDataExchangeRequest.php b/BigQueryAnalyticsHub/src/V1/UpdateDataExchangeRequest.php index fb965d601126..59db98720136 100644 --- a/BigQueryAnalyticsHub/src/V1/UpdateDataExchangeRequest.php +++ b/BigQueryAnalyticsHub/src/V1/UpdateDataExchangeRequest.php @@ -30,6 +30,23 @@ class UpdateDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $data_exchange = null; + /** + * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange Required. The data exchange to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange + * resource. The fields specified in the + * `updateMask` are relative to the resource and are not a full request. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateDataExchangeRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDataExchange($dataExchange) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/UpdateListingRequest.php b/BigQueryAnalyticsHub/src/V1/UpdateListingRequest.php index 016f9a3994db..a58e389a72e3 100644 --- a/BigQueryAnalyticsHub/src/V1/UpdateListingRequest.php +++ b/BigQueryAnalyticsHub/src/V1/UpdateListingRequest.php @@ -30,6 +30,23 @@ class UpdateListingRequest extends \Google\Protobuf\Internal\Message */ private $listing = null; + /** + * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing Required. The listing to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The + * fields specified in the `updateMask` are relative to the resource and are + * not a full request. + * + * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateListingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setListing($listing) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BigQueryAnalyticsHub/src/V1/resources/analytics_hub_service_descriptor_config.php b/BigQueryAnalyticsHub/src/V1/resources/analytics_hub_service_descriptor_config.php index f78ed196b2d0..98a467f77d95 100644 --- a/BigQueryAnalyticsHub/src/V1/resources/analytics_hub_service_descriptor_config.php +++ b/BigQueryAnalyticsHub/src/V1/resources/analytics_hub_service_descriptor_config.php @@ -3,6 +3,90 @@ return [ 'interfaces' => [ 'google.cloud.bigquery.analyticshub.v1.AnalyticsHubService' => [ + 'CreateDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'GetListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'ListDataExchanges' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -12,6 +96,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataExchanges', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListListings' => [ 'pageStreaming' => [ @@ -22,6 +116,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getListings', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListOrgDataExchanges' => [ 'pageStreaming' => [ @@ -32,6 +136,84 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataExchanges', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesResponse', + 'headerParams' => [ + [ + 'keyName' => 'organization', + 'fieldAccessors' => [ + 'getOrganization', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'SubscribeListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'data_exchange.name', + 'fieldAccessors' => [ + 'getDataExchange', + 'getName', + ], + ], + ], + ], + 'UpdateListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'listing.name', + 'fieldAccessors' => [ + 'getListing', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'dataExchange' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}', + 'dataset' => 'projects/{project}/datasets/{dataset}', + 'listing' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}', + 'location' => 'projects/{project}/locations/{location}', ], ], ], diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/Client/AnalyticsHubServiceClientTest.php b/BigQueryAnalyticsHub/tests/Unit/V1/Client/AnalyticsHubServiceClientTest.php similarity index 100% rename from owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/Client/AnalyticsHubServiceClientTest.php rename to BigQueryAnalyticsHub/tests/Unit/V1/Client/AnalyticsHubServiceClientTest.php diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php index 3827a6f10600..0bd0e04b8172 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_CreateDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\CreateDataExchangeRequest; use Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange; /** @@ -52,18 +53,18 @@ function create_data_exchange_sample( // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dataExchange = (new DataExchange()) ->setDisplayName($dataExchangeDisplayName); + $request = (new CreateDataExchangeRequest()) + ->setParent($formattedParent) + ->setDataExchangeId($dataExchangeId) + ->setDataExchange($dataExchange); // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->createDataExchange( - $formattedParent, - $dataExchangeId, - $dataExchange - ); + $response = $analyticsHubServiceClient->createDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php index b2acb0f7b2ec..bcce302a589d 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_CreateListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\CreateListingRequest; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource; @@ -53,16 +54,20 @@ function create_listing_sample( // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $listingBigqueryDataset = new BigQueryDatasetSource(); $listing = (new Listing()) ->setBigqueryDataset($listingBigqueryDataset) ->setDisplayName($listingDisplayName); + $request = (new CreateListingRequest()) + ->setParent($formattedParent) + ->setListingId($listingId) + ->setListing($listing); // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->createListing($formattedParent, $listingId, $listing); + $response = $analyticsHubServiceClient->createListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php index aeec0fe345ac..ab45b1c634a9 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_DeleteDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteDataExchangeRequest; /** * Deletes an existing data exchange. @@ -38,9 +39,13 @@ function delete_data_exchange_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new DeleteDataExchangeRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $analyticsHubServiceClient->deleteDataExchange($formattedName); + $analyticsHubServiceClient->deleteDataExchange($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php index 9834f67c5108..921673c1f39c 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_DeleteListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteListingRequest; /** * Deletes a listing. @@ -38,9 +39,13 @@ function delete_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new DeleteListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $analyticsHubServiceClient->deleteListing($formattedName); + $analyticsHubServiceClient->deleteListing($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php index f1fdb09b8cc2..4e0c3eacae46 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php @@ -24,8 +24,9 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_GetDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange; +use Google\Cloud\BigQuery\DataExchange\V1beta1\GetDataExchangeRequest; /** * Gets the details of a data exchange. @@ -39,10 +40,14 @@ function get_data_exchange_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetDataExchangeRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->getDataExchange($formattedName); + $response = $analyticsHubServiceClient->getDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php index de4a7f4cd2fe..9b5c8745de2c 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -38,10 +39,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $analyticsHubServiceClient->getIamPolicy($resource); + $response = $analyticsHubServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php index 4cccf0c00f7e..ab23f134bd88 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_GetListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\GetListingRequest; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing; /** @@ -39,10 +40,14 @@ function get_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new GetListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->getListing($formattedName); + $response = $analyticsHubServiceClient->getListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_location.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_location.php index 851fba3d3b5a..cfe2b44be3ac 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_location.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/get_location.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $analyticsHubServiceClient->getLocation(); + $response = $analyticsHubServiceClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php index d9c223c836ad..e1c494cef513 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php @@ -25,8 +25,9 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_ListDataExchanges_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange; +use Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesRequest; /** * Lists all data exchanges in a given project and location. @@ -40,10 +41,14 @@ function list_data_exchanges_sample(string $formattedParent): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListDataExchangesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listDataExchanges($formattedParent); + $response = $analyticsHubServiceClient->listDataExchanges($request); /** @var DataExchange $element */ foreach ($response as $element) { diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php index 9d9ed9f58923..768e8d61ab69 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php @@ -25,7 +25,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_ListListings_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsRequest; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing; /** @@ -40,10 +41,14 @@ function list_listings_sample(string $formattedParent): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListListingsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listListings($formattedParent); + $response = $analyticsHubServiceClient->listListings($request); /** @var Listing $element */ foreach ($response as $element) { diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php index c3216086c69a..9b4637aeb55a 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php @@ -25,7 +25,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listLocations(); + $response = $analyticsHubServiceClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php index 365ad26dee49..8610cbfce41e 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php @@ -25,8 +25,9 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_ListOrgDataExchanges_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange; +use Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesRequest; /** * Lists all data exchanges from projects in a given organization and @@ -40,10 +41,14 @@ function list_org_data_exchanges_sample(string $organization): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new ListOrgDataExchangesRequest()) + ->setOrganization($organization); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listOrgDataExchanges($organization); + $response = $analyticsHubServiceClient->listOrgDataExchanges($request); /** @var DataExchange $element */ foreach ($response as $element) { diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php index 22e83015e4e4..b925d755281a 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the IAM policy. @@ -38,13 +39,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $analyticsHubServiceClient->setIamPolicy($resource, $policy); + $response = $analyticsHubServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php index 92190185e888..9e9df85fea17 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_SubscribeListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingRequest; use Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingResponse; /** @@ -44,10 +45,14 @@ function subscribe_listing_sample(string $formattedName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); + // Prepare the request message. + $request = (new SubscribeListingRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var SubscribeListingResponse $response */ - $response = $analyticsHubServiceClient->subscribeListing($formattedName); + $response = $analyticsHubServiceClient->subscribeListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php index acccc5b50538..e02781360407 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -42,13 +43,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $analyticsHubServiceClient->testIamPermissions($resource, $permissions); + $response = $analyticsHubServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php index 45dd39703a6d..f8c2554fd1d9 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php @@ -24,8 +24,9 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_UpdateDataExchange_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange; +use Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateDataExchangeRequest; use Google\Protobuf\FieldMask; /** @@ -42,15 +43,18 @@ function update_data_exchange_sample(string $dataExchangeDisplayName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $dataExchange = (new DataExchange()) ->setDisplayName($dataExchangeDisplayName); + $request = (new UpdateDataExchangeRequest()) + ->setUpdateMask($updateMask) + ->setDataExchange($dataExchange); // Call the API and handle any network failures. try { /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->updateDataExchange($updateMask, $dataExchange); + $response = $analyticsHubServiceClient->updateDataExchange($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php index cb723bee27a8..2b4c4b8a60f4 100644 --- a/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php +++ b/BigQueryDataExchange/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php @@ -24,9 +24,10 @@ // [START analyticshub_v1beta1_generated_AnalyticsHubService_UpdateListing_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataExchange\V1beta1\AnalyticsHubServiceClient; +use Google\Cloud\BigQuery\DataExchange\V1beta1\Client\AnalyticsHubServiceClient; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing; use Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource; +use Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateListingRequest; use Google\Protobuf\FieldMask; /** @@ -43,17 +44,20 @@ function update_listing_sample(string $listingDisplayName): void // Create a client. $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $updateMask = new FieldMask(); $listingBigqueryDataset = new BigQueryDatasetSource(); $listing = (new Listing()) ->setBigqueryDataset($listingBigqueryDataset) ->setDisplayName($listingDisplayName); + $request = (new UpdateListingRequest()) + ->setUpdateMask($updateMask) + ->setListing($listing); // Call the API and handle any network failures. try { /** @var Listing $response */ - $response = $analyticsHubServiceClient->updateListing($updateMask, $listing); + $response = $analyticsHubServiceClient->updateListing($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/Client/AnalyticsHubServiceClient.php b/BigQueryDataExchange/src/V1beta1/Client/AnalyticsHubServiceClient.php similarity index 100% rename from owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/Client/AnalyticsHubServiceClient.php rename to BigQueryDataExchange/src/V1beta1/Client/AnalyticsHubServiceClient.php diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/Client/BaseClient/AnalyticsHubServiceBaseClient.php b/BigQueryDataExchange/src/V1beta1/Client/BaseClient/AnalyticsHubServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/Client/BaseClient/AnalyticsHubServiceBaseClient.php rename to BigQueryDataExchange/src/V1beta1/Client/BaseClient/AnalyticsHubServiceBaseClient.php diff --git a/BigQueryDataExchange/src/V1beta1/CreateDataExchangeRequest.php b/BigQueryDataExchange/src/V1beta1/CreateDataExchangeRequest.php index f65b8586a31e..6ac362075528 100644 --- a/BigQueryDataExchange/src/V1beta1/CreateDataExchangeRequest.php +++ b/BigQueryDataExchange/src/V1beta1/CreateDataExchangeRequest.php @@ -39,6 +39,23 @@ class CreateDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $data_exchange = null; + /** + * @param string $parent Required. The parent resource path of the data exchange. + * e.g. `projects/myproject/locations/US`. Please see + * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange Required. The data exchange to create. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateDataExchangeRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange): self + { + return (new self()) + ->setParent($parent) + ->setDataExchange($dataExchange); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/CreateListingRequest.php b/BigQueryDataExchange/src/V1beta1/CreateListingRequest.php index da073dbf82dd..3c0c0101a785 100644 --- a/BigQueryDataExchange/src/V1beta1/CreateListingRequest.php +++ b/BigQueryDataExchange/src/V1beta1/CreateListingRequest.php @@ -39,6 +39,23 @@ class CreateListingRequest extends \Google\Protobuf\Internal\Message */ private $listing = null; + /** + * @param string $parent Required. The parent resource path of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing Required. The listing to create. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateListingRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing): self + { + return (new self()) + ->setParent($parent) + ->setListing($listing); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/DeleteDataExchangeRequest.php b/BigQueryDataExchange/src/V1beta1/DeleteDataExchangeRequest.php index defca3b99d75..c00cf4a55c8b 100644 --- a/BigQueryDataExchange/src/V1beta1/DeleteDataExchangeRequest.php +++ b/BigQueryDataExchange/src/V1beta1/DeleteDataExchangeRequest.php @@ -23,6 +23,21 @@ class DeleteDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The full name of the data exchange resource that you want to delete. + * For example, `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteDataExchangeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/DeleteListingRequest.php b/BigQueryDataExchange/src/V1beta1/DeleteListingRequest.php index ee922b4891a9..c8456aa21f01 100644 --- a/BigQueryDataExchange/src/V1beta1/DeleteListingRequest.php +++ b/BigQueryDataExchange/src/V1beta1/DeleteListingRequest.php @@ -23,6 +23,21 @@ class DeleteListingRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Resource name of the listing to delete. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/GetDataExchangeRequest.php b/BigQueryDataExchange/src/V1beta1/GetDataExchangeRequest.php index c18fa247730f..33f3dcbd526d 100644 --- a/BigQueryDataExchange/src/V1beta1/GetDataExchangeRequest.php +++ b/BigQueryDataExchange/src/V1beta1/GetDataExchangeRequest.php @@ -23,6 +23,21 @@ class GetDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the data exchange. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\GetDataExchangeRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/GetListingRequest.php b/BigQueryDataExchange/src/V1beta1/GetListingRequest.php index 18a68b81d0cc..f93cd882e7d8 100644 --- a/BigQueryDataExchange/src/V1beta1/GetListingRequest.php +++ b/BigQueryDataExchange/src/V1beta1/GetListingRequest.php @@ -23,6 +23,21 @@ class GetListingRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The resource name of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\GetListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/ListDataExchangesRequest.php b/BigQueryDataExchange/src/V1beta1/ListDataExchangesRequest.php index 8a9ac9fdd945..1aa0115fd49c 100644 --- a/BigQueryDataExchange/src/V1beta1/ListDataExchangesRequest.php +++ b/BigQueryDataExchange/src/V1beta1/ListDataExchangesRequest.php @@ -37,6 +37,21 @@ class ListDataExchangesRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The parent resource path of the data exchanges. + * e.g. `projects/myproject/locations/US`. Please see + * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/ListListingsRequest.php b/BigQueryDataExchange/src/V1beta1/ListListingsRequest.php index f8db88544b26..406f8b017c53 100644 --- a/BigQueryDataExchange/src/V1beta1/ListListingsRequest.php +++ b/BigQueryDataExchange/src/V1beta1/ListListingsRequest.php @@ -37,6 +37,21 @@ class ListListingsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The parent resource path of the listing. + * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see + * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/ListOrgDataExchangesRequest.php b/BigQueryDataExchange/src/V1beta1/ListOrgDataExchangesRequest.php index 2cee4efe2c24..b9388b42cd0f 100644 --- a/BigQueryDataExchange/src/V1beta1/ListOrgDataExchangesRequest.php +++ b/BigQueryDataExchange/src/V1beta1/ListOrgDataExchangesRequest.php @@ -38,6 +38,20 @@ class ListOrgDataExchangesRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $organization Required. The organization resource path of the projects containing DataExchanges. + * e.g. `organizations/myorg/locations/US`. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesRequest + * + * @experimental + */ + public static function build(string $organization): self + { + return (new self()) + ->setOrganization($organization); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/SubscribeListingRequest.php b/BigQueryDataExchange/src/V1beta1/SubscribeListingRequest.php index 132f28d879e6..3735bf42a546 100644 --- a/BigQueryDataExchange/src/V1beta1/SubscribeListingRequest.php +++ b/BigQueryDataExchange/src/V1beta1/SubscribeListingRequest.php @@ -24,6 +24,21 @@ class SubscribeListingRequest extends \Google\Protobuf\Internal\Message private $name = ''; protected $destination; + /** + * @param string $name Required. Resource name of the listing that you want to subscribe to. + * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see + * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/UpdateDataExchangeRequest.php b/BigQueryDataExchange/src/V1beta1/UpdateDataExchangeRequest.php index 344c71a64f39..a9013098043d 100644 --- a/BigQueryDataExchange/src/V1beta1/UpdateDataExchangeRequest.php +++ b/BigQueryDataExchange/src/V1beta1/UpdateDataExchangeRequest.php @@ -30,6 +30,23 @@ class UpdateDataExchangeRequest extends \Google\Protobuf\Internal\Message */ private $data_exchange = null; + /** + * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange Required. The data exchange to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange + * resource. The fields specified in the + * `updateMask` are relative to the resource and are not a full request. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateDataExchangeRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDataExchange($dataExchange) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/UpdateListingRequest.php b/BigQueryDataExchange/src/V1beta1/UpdateListingRequest.php index 24cc2d2004fb..2c0e43ec44cc 100644 --- a/BigQueryDataExchange/src/V1beta1/UpdateListingRequest.php +++ b/BigQueryDataExchange/src/V1beta1/UpdateListingRequest.php @@ -30,6 +30,23 @@ class UpdateListingRequest extends \Google\Protobuf\Internal\Message */ private $listing = null; + /** + * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing Required. The listing to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The + * fields specified in the `updateMask` are relative to the resource and are + * not a full request. + * + * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateListingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setListing($listing) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BigQueryDataExchange/src/V1beta1/resources/analytics_hub_service_descriptor_config.php b/BigQueryDataExchange/src/V1beta1/resources/analytics_hub_service_descriptor_config.php index bbf1c282901d..483a7d7da69f 100644 --- a/BigQueryDataExchange/src/V1beta1/resources/analytics_hub_service_descriptor_config.php +++ b/BigQueryDataExchange/src/V1beta1/resources/analytics_hub_service_descriptor_config.php @@ -3,6 +3,90 @@ return [ 'interfaces' => [ 'google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService' => [ + 'CreateDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'GetListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'ListDataExchanges' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -12,6 +96,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataExchanges', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListListings' => [ 'pageStreaming' => [ @@ -22,6 +116,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getListings', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListOrgDataExchanges' => [ 'pageStreaming' => [ @@ -32,8 +136,90 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataExchanges', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesResponse', + 'headerParams' => [ + [ + 'keyName' => 'organization', + 'fieldAccessors' => [ + 'getOrganization', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'SubscribeListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateDataExchange' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', + 'headerParams' => [ + [ + 'keyName' => 'data_exchange.name', + 'fieldAccessors' => [ + 'getDataExchange', + 'getName', + ], + ], + ], + ], + 'UpdateListing' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', + 'headerParams' => [ + [ + 'keyName' => 'listing.name', + 'fieldAccessors' => [ + 'getListing', + 'getName', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -45,8 +231,24 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], + 'templateMap' => [ + 'dataExchange' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}', + 'dataset' => 'projects/{project}/datasets/{dataset}', + 'listing' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/Client/AnalyticsHubServiceClientTest.php b/BigQueryDataExchange/tests/Unit/V1beta1/Client/AnalyticsHubServiceClientTest.php similarity index 100% rename from owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/Client/AnalyticsHubServiceClientTest.php rename to BigQueryDataExchange/tests/Unit/V1beta1/Client/AnalyticsHubServiceClientTest.php diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/create_data_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/create_data_policy.php index aba7061014b4..1644a2e5f03a 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/create_data_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/create_data_policy.php @@ -24,8 +24,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_CreateDataPolicy_sync] use Google\ApiCore\ApiException; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\CreateDataPolicyRequest; use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; /** * Creates a new data policy under a project with the given `dataPolicyId` @@ -40,13 +41,16 @@ function create_data_policy_sample(string $formattedParent): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dataPolicy = new DataPolicy(); + $request = (new CreateDataPolicyRequest()) + ->setParent($formattedParent) + ->setDataPolicy($dataPolicy); // Call the API and handle any network failures. try { /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->createDataPolicy($formattedParent, $dataPolicy); + $response = $dataPolicyServiceClient->createDataPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/delete_data_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/delete_data_policy.php index d80ccbda5608..1ff7c2b2f8dc 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/delete_data_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/delete_data_policy.php @@ -24,7 +24,8 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_DeleteDataPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\DeleteDataPolicyRequest; /** * Deletes the data policy specified by its resource name. @@ -38,9 +39,13 @@ function delete_data_policy_sample(string $formattedName): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); + // Prepare the request message. + $request = (new DeleteDataPolicyRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataPolicyServiceClient->deleteDataPolicy($formattedName); + $dataPolicyServiceClient->deleteDataPolicy($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_data_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_data_policy.php index b5384d195f23..57e367b6c8b0 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_data_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_data_policy.php @@ -24,8 +24,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_GetDataPolicy_sync] use Google\ApiCore\ApiException; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\GetDataPolicyRequest; /** * Gets the data policy specified by its resource name. @@ -39,10 +40,14 @@ function get_data_policy_sample(string $formattedName): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); + // Prepare the request message. + $request = (new GetDataPolicyRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->getDataPolicy($formattedName); + $response = $dataPolicyServiceClient->getDataPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_iam_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_iam_policy.php index 602f4ee4495f..d1dbe6d77bf9 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_iam_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -38,10 +39,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $dataPolicyServiceClient->getIamPolicy($resource); + $response = $dataPolicyServiceClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/list_data_policies.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/list_data_policies.php index 111cdcecbbae..1aa07e6dd506 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/list_data_policies.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/list_data_policies.php @@ -25,8 +25,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_ListDataPolicies_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesRequest; /** * List all of the data policies in the specified parent project. @@ -40,10 +41,14 @@ function list_data_policies_sample(string $formattedParent): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); + // Prepare the request message. + $request = (new ListDataPoliciesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataPolicyServiceClient->listDataPolicies($formattedParent); + $response = $dataPolicyServiceClient->listDataPolicies($request); /** @var DataPolicy $element */ foreach ($response as $element) { diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/rename_data_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/rename_data_policy.php index e8d3f96c7ca7..347f80076fff 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/rename_data_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/rename_data_policy.php @@ -24,8 +24,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_RenameDataPolicy_sync] use Google\ApiCore\ApiException; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\RenameDataPolicyRequest; /** * Renames the id (display name) of the specified data policy. @@ -39,10 +40,15 @@ function rename_data_policy_sample(string $name, string $newDataPolicyId): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); + // Prepare the request message. + $request = (new RenameDataPolicyRequest()) + ->setName($name) + ->setNewDataPolicyId($newDataPolicyId); + // Call the API and handle any network failures. try { /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->renameDataPolicy($name, $newDataPolicyId); + $response = $dataPolicyServiceClient->renameDataPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/set_iam_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/set_iam_policy.php index 6c42621189ed..a085230bebf7 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/set_iam_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the IAM policy for the specified data policy. @@ -38,13 +39,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $dataPolicyServiceClient->setIamPolicy($resource, $policy); + $response = $dataPolicyServiceClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/test_iam_permissions.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/test_iam_permissions.php index 99e6d19e3da5..14dafcc60d24 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/test_iam_permissions.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -42,13 +43,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $dataPolicyServiceClient->testIamPermissions($resource, $permissions); + $response = $dataPolicyServiceClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/update_data_policy.php b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/update_data_policy.php index f5ac566bcb0e..a23c5c164e83 100644 --- a/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/update_data_policy.php +++ b/BigQueryDataPolicies/samples/V1/DataPolicyServiceClient/update_data_policy.php @@ -24,8 +24,9 @@ // [START bigquerydatapolicy_v1_generated_DataPolicyService_UpdateDataPolicy_sync] use Google\ApiCore\ApiException; +use Google\Cloud\BigQuery\DataPolicies\V1\Client\DataPolicyServiceClient; use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy; -use Google\Cloud\BigQuery\DataPolicies\V1\DataPolicyServiceClient; +use Google\Cloud\BigQuery\DataPolicies\V1\UpdateDataPolicyRequest; /** * Updates the metadata for an existing data policy. The target data policy @@ -42,13 +43,15 @@ function update_data_policy_sample(): void // Create a client. $dataPolicyServiceClient = new DataPolicyServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dataPolicy = new DataPolicy(); + $request = (new UpdateDataPolicyRequest()) + ->setDataPolicy($dataPolicy); // Call the API and handle any network failures. try { /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->updateDataPolicy($dataPolicy); + $response = $dataPolicyServiceClient->updateDataPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/Client/BaseClient/DataPolicyServiceBaseClient.php b/BigQueryDataPolicies/src/V1/Client/BaseClient/DataPolicyServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BigQueryDataPolicies/v1/src/V1/Client/BaseClient/DataPolicyServiceBaseClient.php rename to BigQueryDataPolicies/src/V1/Client/BaseClient/DataPolicyServiceBaseClient.php diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/Client/DataPolicyServiceClient.php b/BigQueryDataPolicies/src/V1/Client/DataPolicyServiceClient.php similarity index 100% rename from owl-bot-staging/BigQueryDataPolicies/v1/src/V1/Client/DataPolicyServiceClient.php rename to BigQueryDataPolicies/src/V1/Client/DataPolicyServiceClient.php diff --git a/BigQueryDataPolicies/src/V1/CreateDataPolicyRequest.php b/BigQueryDataPolicies/src/V1/CreateDataPolicyRequest.php index b0d97987ab5e..c6b61958897a 100644 --- a/BigQueryDataPolicies/src/V1/CreateDataPolicyRequest.php +++ b/BigQueryDataPolicies/src/V1/CreateDataPolicyRequest.php @@ -30,6 +30,24 @@ class CreateDataPolicyRequest extends \Google\Protobuf\Internal\Message */ private $data_policy = null; + /** + * @param string $parent Required. Resource name of the project that the data policy will belong to. + * The format is `projects/{project_number}/locations/{location_id}`. Please see + * {@see DataPolicyServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy Required. The data policy to create. The `name` field does not need to be + * provided for the data policy creation. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\CreateDataPolicyRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy): self + { + return (new self()) + ->setParent($parent) + ->setDataPolicy($dataPolicy); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/DeleteDataPolicyRequest.php b/BigQueryDataPolicies/src/V1/DeleteDataPolicyRequest.php index 37108cd4b082..aa5a975f24b3 100644 --- a/BigQueryDataPolicies/src/V1/DeleteDataPolicyRequest.php +++ b/BigQueryDataPolicies/src/V1/DeleteDataPolicyRequest.php @@ -23,6 +23,21 @@ class DeleteDataPolicyRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Resource name of the data policy to delete. Format is + * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. Please see + * {@see DataPolicyServiceClient::dataPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\DeleteDataPolicyRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/GetDataPolicyRequest.php b/BigQueryDataPolicies/src/V1/GetDataPolicyRequest.php index de11e4ada486..129f93edf69c 100644 --- a/BigQueryDataPolicies/src/V1/GetDataPolicyRequest.php +++ b/BigQueryDataPolicies/src/V1/GetDataPolicyRequest.php @@ -23,6 +23,21 @@ class GetDataPolicyRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Resource name of the requested data policy. Format is + * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. Please see + * {@see DataPolicyServiceClient::dataPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\GetDataPolicyRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/ListDataPoliciesRequest.php b/BigQueryDataPolicies/src/V1/ListDataPoliciesRequest.php index ec169c1d3918..3e2b77351376 100644 --- a/BigQueryDataPolicies/src/V1/ListDataPoliciesRequest.php +++ b/BigQueryDataPolicies/src/V1/ListDataPoliciesRequest.php @@ -50,6 +50,21 @@ class ListDataPoliciesRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. Resource name of the project for which to list data policies. + * Format is `projects/{project_number}/locations/{location_id}`. Please see + * {@see DataPolicyServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/RenameDataPolicyRequest.php b/BigQueryDataPolicies/src/V1/RenameDataPolicyRequest.php index b3830f8fa7c2..0a3bf2198768 100644 --- a/BigQueryDataPolicies/src/V1/RenameDataPolicyRequest.php +++ b/BigQueryDataPolicies/src/V1/RenameDataPolicyRequest.php @@ -29,6 +29,22 @@ class RenameDataPolicyRequest extends \Google\Protobuf\Internal\Message */ private $new_data_policy_id = ''; + /** + * @param string $name Required. Resource name of the data policy to rename. The format is + * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` + * @param string $newDataPolicyId Required. The new data policy id. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\RenameDataPolicyRequest + * + * @experimental + */ + public static function build(string $name, string $newDataPolicyId): self + { + return (new self()) + ->setName($name) + ->setNewDataPolicyId($newDataPolicyId); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/UpdateDataPolicyRequest.php b/BigQueryDataPolicies/src/V1/UpdateDataPolicyRequest.php index c9126ed81880..69396dcaa781 100644 --- a/BigQueryDataPolicies/src/V1/UpdateDataPolicyRequest.php +++ b/BigQueryDataPolicies/src/V1/UpdateDataPolicyRequest.php @@ -34,6 +34,29 @@ class UpdateDataPolicyRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy Required. Update the data policy's metadata. + * + * The target data policy is determined by the `name` field. + * Other fields are updated to the specified values based on the field masks. + * @param \Google\Protobuf\FieldMask $updateMask The update mask applies to the resource. For the `FieldMask` definition, + * see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + * If not set, defaults to all of the fields that are allowed to update. + * + * Updates to the `name` and `dataPolicyId` fields are not allowed. + * + * @return \Google\Cloud\BigQuery\DataPolicies\V1\UpdateDataPolicyRequest + * + * @experimental + */ + public static function build(\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDataPolicy($dataPolicy) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/BigQueryDataPolicies/src/V1/resources/data_policy_service_descriptor_config.php b/BigQueryDataPolicies/src/V1/resources/data_policy_service_descriptor_config.php index 6aca9ce454e2..cda5186072b8 100644 --- a/BigQueryDataPolicies/src/V1/resources/data_policy_service_descriptor_config.php +++ b/BigQueryDataPolicies/src/V1/resources/data_policy_service_descriptor_config.php @@ -3,6 +3,54 @@ return [ 'interfaces' => [ 'google.cloud.bigquery.datapolicies.v1.DataPolicyService' => [ + 'CreateDataPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteDataPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], 'ListDataPolicies' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -12,6 +60,69 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataPolicies', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'RenameDataPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateDataPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', + 'headerParams' => [ + [ + 'keyName' => 'data_policy.name', + 'fieldAccessors' => [ + 'getDataPolicy', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'dataPolicy' => 'projects/{project}/locations/{location}/dataPolicies/{data_policy}', + 'location' => 'projects/{project}/locations/{location}', ], ], ], diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/Client/DataPolicyServiceClientTest.php b/BigQueryDataPolicies/tests/Unit/V1/Client/DataPolicyServiceClientTest.php similarity index 100% rename from owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/Client/DataPolicyServiceClientTest.php rename to BigQueryDataPolicies/tests/Unit/V1/Client/DataPolicyServiceClientTest.php diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/create_migration_workflow.php b/BigQueryMigration/samples/V2/MigrationServiceClient/create_migration_workflow.php index 5d313c41e368..b6de6ab4a6f4 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/create_migration_workflow.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/create_migration_workflow.php @@ -24,7 +24,8 @@ // [START bigquerymigration_v2_generated_MigrationService_CreateMigrationWorkflow_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\CreateMigrationWorkflowRequest; use Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow; /** @@ -39,13 +40,16 @@ function create_migration_workflow_sample(string $formattedParent): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $migrationWorkflow = new MigrationWorkflow(); + $request = (new CreateMigrationWorkflowRequest()) + ->setParent($formattedParent) + ->setMigrationWorkflow($migrationWorkflow); // Call the API and handle any network failures. try { /** @var MigrationWorkflow $response */ - $response = $migrationServiceClient->createMigrationWorkflow($formattedParent, $migrationWorkflow); + $response = $migrationServiceClient->createMigrationWorkflow($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/delete_migration_workflow.php b/BigQueryMigration/samples/V2/MigrationServiceClient/delete_migration_workflow.php index 2a96e73b8fac..c3eb604ba1f9 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/delete_migration_workflow.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/delete_migration_workflow.php @@ -24,7 +24,8 @@ // [START bigquerymigration_v2_generated_MigrationService_DeleteMigrationWorkflow_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\DeleteMigrationWorkflowRequest; /** * Deletes a migration workflow by name. @@ -38,9 +39,13 @@ function delete_migration_workflow_sample(string $formattedName): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new DeleteMigrationWorkflowRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $migrationServiceClient->deleteMigrationWorkflow($formattedName); + $migrationServiceClient->deleteMigrationWorkflow($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_subtask.php b/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_subtask.php index ae4a71250879..e6ffa30a08bf 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_subtask.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_subtask.php @@ -24,7 +24,8 @@ // [START bigquerymigration_v2_generated_MigrationService_GetMigrationSubtask_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\GetMigrationSubtaskRequest; use Google\Cloud\BigQuery\Migration\V2\MigrationSubtask; /** @@ -39,10 +40,14 @@ function get_migration_subtask_sample(string $formattedName): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new GetMigrationSubtaskRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var MigrationSubtask $response */ - $response = $migrationServiceClient->getMigrationSubtask($formattedName); + $response = $migrationServiceClient->getMigrationSubtask($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_workflow.php b/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_workflow.php index f808a29bcb0b..3b9111960499 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_workflow.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/get_migration_workflow.php @@ -24,7 +24,8 @@ // [START bigquerymigration_v2_generated_MigrationService_GetMigrationWorkflow_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\GetMigrationWorkflowRequest; use Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow; /** @@ -39,10 +40,14 @@ function get_migration_workflow_sample(string $formattedName): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new GetMigrationWorkflowRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var MigrationWorkflow $response */ - $response = $migrationServiceClient->getMigrationWorkflow($formattedName); + $response = $migrationServiceClient->getMigrationWorkflow($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_subtasks.php b/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_subtasks.php index f4257b264730..4412c83b4c06 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_subtasks.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_subtasks.php @@ -25,7 +25,8 @@ // [START bigquerymigration_v2_generated_MigrationService_ListMigrationSubtasks_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksRequest; use Google\Cloud\BigQuery\Migration\V2\MigrationSubtask; /** @@ -40,10 +41,14 @@ function list_migration_subtasks_sample(string $formattedParent): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new ListMigrationSubtasksRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $migrationServiceClient->listMigrationSubtasks($formattedParent); + $response = $migrationServiceClient->listMigrationSubtasks($request); /** @var MigrationSubtask $element */ foreach ($response as $element) { diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_workflows.php b/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_workflows.php index 6e94aeb18ece..3200fdeb7acf 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_workflows.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/list_migration_workflows.php @@ -25,7 +25,8 @@ // [START bigquerymigration_v2_generated_MigrationService_ListMigrationWorkflows_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsRequest; use Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow; /** @@ -40,10 +41,14 @@ function list_migration_workflows_sample(string $formattedParent): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new ListMigrationWorkflowsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $migrationServiceClient->listMigrationWorkflows($formattedParent); + $response = $migrationServiceClient->listMigrationWorkflows($request); /** @var MigrationWorkflow $element */ foreach ($response as $element) { diff --git a/BigQueryMigration/samples/V2/MigrationServiceClient/start_migration_workflow.php b/BigQueryMigration/samples/V2/MigrationServiceClient/start_migration_workflow.php index 1b8c7bc14006..f761d27a94af 100644 --- a/BigQueryMigration/samples/V2/MigrationServiceClient/start_migration_workflow.php +++ b/BigQueryMigration/samples/V2/MigrationServiceClient/start_migration_workflow.php @@ -24,7 +24,8 @@ // [START bigquerymigration_v2_generated_MigrationService_StartMigrationWorkflow_sync] use Google\ApiCore\ApiException; -use Google\Cloud\BigQuery\Migration\V2\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\Client\MigrationServiceClient; +use Google\Cloud\BigQuery\Migration\V2\StartMigrationWorkflowRequest; /** * Starts a previously created migration workflow. I.e., the state transitions @@ -41,9 +42,13 @@ function start_migration_workflow_sample(string $formattedName): void // Create a client. $migrationServiceClient = new MigrationServiceClient(); + // Prepare the request message. + $request = (new StartMigrationWorkflowRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $migrationServiceClient->startMigrationWorkflow($formattedName); + $migrationServiceClient->startMigrationWorkflow($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/BigQueryMigration/v2/src/V2/Client/BaseClient/MigrationServiceBaseClient.php b/BigQueryMigration/src/V2/Client/BaseClient/MigrationServiceBaseClient.php similarity index 100% rename from owl-bot-staging/BigQueryMigration/v2/src/V2/Client/BaseClient/MigrationServiceBaseClient.php rename to BigQueryMigration/src/V2/Client/BaseClient/MigrationServiceBaseClient.php diff --git a/owl-bot-staging/BigQueryMigration/v2/src/V2/Client/MigrationServiceClient.php b/BigQueryMigration/src/V2/Client/MigrationServiceClient.php similarity index 100% rename from owl-bot-staging/BigQueryMigration/v2/src/V2/Client/MigrationServiceClient.php rename to BigQueryMigration/src/V2/Client/MigrationServiceClient.php diff --git a/BigQueryMigration/src/V2/CreateMigrationWorkflowRequest.php b/BigQueryMigration/src/V2/CreateMigrationWorkflowRequest.php index 432d7c12c47e..d673a137d99a 100644 --- a/BigQueryMigration/src/V2/CreateMigrationWorkflowRequest.php +++ b/BigQueryMigration/src/V2/CreateMigrationWorkflowRequest.php @@ -29,6 +29,23 @@ class CreateMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message */ private $migration_workflow = null; + /** + * @param string $parent Required. The name of the project to which this migration workflow belongs. + * Example: `projects/foo/locations/bar` + * Please see {@see MigrationServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $migrationWorkflow Required. The migration workflow to create. + * + * @return \Google\Cloud\BigQuery\Migration\V2\CreateMigrationWorkflowRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $migrationWorkflow): self + { + return (new self()) + ->setParent($parent) + ->setMigrationWorkflow($migrationWorkflow); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/DeleteMigrationWorkflowRequest.php b/BigQueryMigration/src/V2/DeleteMigrationWorkflowRequest.php index 8ba3c264727d..ef69dd87435e 100644 --- a/BigQueryMigration/src/V2/DeleteMigrationWorkflowRequest.php +++ b/BigQueryMigration/src/V2/DeleteMigrationWorkflowRequest.php @@ -23,6 +23,21 @@ class DeleteMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The unique identifier for the migration workflow. + * Example: `projects/123/locations/us/workflows/1234` + * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\DeleteMigrationWorkflowRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/GetMigrationSubtaskRequest.php b/BigQueryMigration/src/V2/GetMigrationSubtaskRequest.php index 73768a3be162..5627e9519448 100644 --- a/BigQueryMigration/src/V2/GetMigrationSubtaskRequest.php +++ b/BigQueryMigration/src/V2/GetMigrationSubtaskRequest.php @@ -29,6 +29,21 @@ class GetMigrationSubtaskRequest extends \Google\Protobuf\Internal\Message */ private $read_mask = null; + /** + * @param string $name Required. The unique identifier for the migration subtask. + * Example: `projects/123/locations/us/workflows/1234/subtasks/543` + * Please see {@see MigrationServiceClient::migrationSubtaskName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\GetMigrationSubtaskRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/GetMigrationWorkflowRequest.php b/BigQueryMigration/src/V2/GetMigrationWorkflowRequest.php index 5445a2c3f287..29cd77620b7b 100644 --- a/BigQueryMigration/src/V2/GetMigrationWorkflowRequest.php +++ b/BigQueryMigration/src/V2/GetMigrationWorkflowRequest.php @@ -29,6 +29,21 @@ class GetMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message */ private $read_mask = null; + /** + * @param string $name Required. The unique identifier for the migration workflow. + * Example: `projects/123/locations/us/workflows/1234` + * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\GetMigrationWorkflowRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/ListMigrationSubtasksRequest.php b/BigQueryMigration/src/V2/ListMigrationSubtasksRequest.php index d05d2c9d8165..f70c040f150b 100644 --- a/BigQueryMigration/src/V2/ListMigrationSubtasksRequest.php +++ b/BigQueryMigration/src/V2/ListMigrationSubtasksRequest.php @@ -53,6 +53,21 @@ class ListMigrationSubtasksRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The migration task of the subtasks to list. + * Example: `projects/123/locations/us/workflows/1234` + * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/ListMigrationWorkflowsRequest.php b/BigQueryMigration/src/V2/ListMigrationWorkflowsRequest.php index 9488202071b1..3e4b4285a52d 100644 --- a/BigQueryMigration/src/V2/ListMigrationWorkflowsRequest.php +++ b/BigQueryMigration/src/V2/ListMigrationWorkflowsRequest.php @@ -45,6 +45,21 @@ class ListMigrationWorkflowsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The project and location of the migration workflows to list. + * Example: `projects/123/locations/us` + * Please see {@see MigrationServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/StartMigrationWorkflowRequest.php b/BigQueryMigration/src/V2/StartMigrationWorkflowRequest.php index e4a89b8edb27..87188a961f53 100644 --- a/BigQueryMigration/src/V2/StartMigrationWorkflowRequest.php +++ b/BigQueryMigration/src/V2/StartMigrationWorkflowRequest.php @@ -23,6 +23,21 @@ class StartMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The unique identifier for the migration workflow. + * Example: `projects/123/locations/us/workflows/1234` + * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. + * + * @return \Google\Cloud\BigQuery\Migration\V2\StartMigrationWorkflowRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/BigQueryMigration/src/V2/resources/migration_service_descriptor_config.php b/BigQueryMigration/src/V2/resources/migration_service_descriptor_config.php index 5eaacc8068d1..f1301a436a11 100644 --- a/BigQueryMigration/src/V2/resources/migration_service_descriptor_config.php +++ b/BigQueryMigration/src/V2/resources/migration_service_descriptor_config.php @@ -3,6 +3,54 @@ return [ 'interfaces' => [ 'google.cloud.bigquery.migration.v2.MigrationService' => [ + 'CreateMigrationWorkflow' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteMigrationWorkflow' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetMigrationSubtask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationSubtask', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetMigrationWorkflow' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'ListMigrationSubtasks' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -12,6 +60,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getMigrationSubtasks', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListMigrationWorkflows' => [ 'pageStreaming' => [ @@ -22,6 +80,33 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getMigrationWorkflows', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'StartMigrationWorkflow' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'location' => 'projects/{project}/locations/{location}', + 'migrationSubtask' => 'projects/{project}/locations/{location}/workflows/{workflow}/subtasks/{subtask}', + 'migrationWorkflow' => 'projects/{project}/locations/{location}/workflows/{workflow}', ], ], ], diff --git a/owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/Client/MigrationServiceClientTest.php b/BigQueryMigration/tests/Unit/V2/Client/MigrationServiceClientTest.php similarity index 100% rename from owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/Client/MigrationServiceClientTest.php rename to BigQueryMigration/tests/Unit/V2/Client/MigrationServiceClientTest.php diff --git a/Build/samples/V2/RepositoryManagerClient/batch_create_repositories.php b/Build/samples/V2/RepositoryManagerClient/batch_create_repositories.php index 75c1b5969e6b..bd8eef0debf8 100644 --- a/Build/samples/V2/RepositoryManagerClient/batch_create_repositories.php +++ b/Build/samples/V2/RepositoryManagerClient/batch_create_repositories.php @@ -25,10 +25,11 @@ // [START cloudbuild_v2_generated_RepositoryManager_BatchCreateRepositories_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; +use Google\Cloud\Build\V2\BatchCreateRepositoriesRequest; use Google\Cloud\Build\V2\BatchCreateRepositoriesResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Build\V2\CreateRepositoryRequest; use Google\Cloud\Build\V2\Repository; -use Google\Cloud\Build\V2\RepositoryManagerClient; use Google\Rpc\Status; /** @@ -58,7 +59,7 @@ function batch_create_repositories_sample( // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $requestsRepository = (new Repository()) ->setRemoteUri($requestsRepositoryRemoteUri); $createRepositoryRequest = (new CreateRepositoryRequest()) @@ -66,11 +67,14 @@ function batch_create_repositories_sample( ->setRepository($requestsRepository) ->setRepositoryId($requestsRepositoryId); $requests = [$createRepositoryRequest,]; + $request = (new BatchCreateRepositoriesRequest()) + ->setParent($formattedParent) + ->setRequests($requests); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->batchCreateRepositories($formattedParent, $requests); + $response = $repositoryManagerClient->batchCreateRepositories($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/samples/V2/RepositoryManagerClient/create_connection.php b/Build/samples/V2/RepositoryManagerClient/create_connection.php index 8a1b5e8e93ff..8b83e8387ccd 100644 --- a/Build/samples/V2/RepositoryManagerClient/create_connection.php +++ b/Build/samples/V2/RepositoryManagerClient/create_connection.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_CreateConnection_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Build\V2\Connection; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\CreateConnectionRequest; use Google\Rpc\Status; /** @@ -45,17 +46,17 @@ function create_connection_sample(string $formattedParent, string $connectionId) // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $connection = new Connection(); + $request = (new CreateConnectionRequest()) + ->setParent($formattedParent) + ->setConnection($connection) + ->setConnectionId($connectionId); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->createConnection( - $formattedParent, - $connection, - $connectionId - ); + $response = $repositoryManagerClient->createConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/samples/V2/RepositoryManagerClient/create_repository.php b/Build/samples/V2/RepositoryManagerClient/create_repository.php index 0942338e4198..49155728473e 100644 --- a/Build/samples/V2/RepositoryManagerClient/create_repository.php +++ b/Build/samples/V2/RepositoryManagerClient/create_repository.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_CreateRepository_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\CreateRepositoryRequest; use Google\Cloud\Build\V2\Repository; -use Google\Cloud\Build\V2\RepositoryManagerClient; use Google\Rpc\Status; /** @@ -50,18 +51,18 @@ function create_repository_sample( // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $repository = (new Repository()) ->setRemoteUri($repositoryRemoteUri); + $request = (new CreateRepositoryRequest()) + ->setParent($formattedParent) + ->setRepository($repository) + ->setRepositoryId($repositoryId); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->createRepository( - $formattedParent, - $repository, - $repositoryId - ); + $response = $repositoryManagerClient->createRepository($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/samples/V2/RepositoryManagerClient/delete_connection.php b/Build/samples/V2/RepositoryManagerClient/delete_connection.php index 1d8a5eb974f1..d8364f47874d 100644 --- a/Build/samples/V2/RepositoryManagerClient/delete_connection.php +++ b/Build/samples/V2/RepositoryManagerClient/delete_connection.php @@ -25,7 +25,8 @@ // [START cloudbuild_v2_generated_RepositoryManager_DeleteConnection_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\DeleteConnectionRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_connection_sample(string $formattedName): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new DeleteConnectionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->deleteConnection($formattedName); + $response = $repositoryManagerClient->deleteConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/samples/V2/RepositoryManagerClient/delete_repository.php b/Build/samples/V2/RepositoryManagerClient/delete_repository.php index cf5a22b4db15..28a2a6ef7286 100644 --- a/Build/samples/V2/RepositoryManagerClient/delete_repository.php +++ b/Build/samples/V2/RepositoryManagerClient/delete_repository.php @@ -25,7 +25,8 @@ // [START cloudbuild_v2_generated_RepositoryManager_DeleteRepository_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\DeleteRepositoryRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_repository_sample(string $formattedName): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new DeleteRepositoryRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->deleteRepository($formattedName); + $response = $repositoryManagerClient->deleteRepository($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php b/Build/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php index 54e60c1b4b3c..6f16c82006c7 100644 --- a/Build/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php +++ b/Build/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_FetchLinkableRepositories_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\FetchLinkableRepositoriesRequest; use Google\Cloud\Build\V2\Repository; -use Google\Cloud\Build\V2\RepositoryManagerClient; /** * FetchLinkableRepositories get repositories from SCM that are @@ -41,10 +42,14 @@ function fetch_linkable_repositories_sample(string $formattedConnection): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new FetchLinkableRepositoriesRequest()) + ->setConnection($formattedConnection); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->fetchLinkableRepositories($formattedConnection); + $response = $repositoryManagerClient->fetchLinkableRepositories($request); /** @var Repository $element */ foreach ($response as $element) { diff --git a/Build/samples/V2/RepositoryManagerClient/fetch_read_token.php b/Build/samples/V2/RepositoryManagerClient/fetch_read_token.php index f57da799894c..3ff6330d2f0f 100644 --- a/Build/samples/V2/RepositoryManagerClient/fetch_read_token.php +++ b/Build/samples/V2/RepositoryManagerClient/fetch_read_token.php @@ -24,8 +24,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_FetchReadToken_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\FetchReadTokenRequest; use Google\Cloud\Build\V2\FetchReadTokenResponse; -use Google\Cloud\Build\V2\RepositoryManagerClient; /** * Fetches read token of a given repository. @@ -39,10 +40,14 @@ function fetch_read_token_sample(string $formattedRepository): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new FetchReadTokenRequest()) + ->setRepository($formattedRepository); + // Call the API and handle any network failures. try { /** @var FetchReadTokenResponse $response */ - $response = $repositoryManagerClient->fetchReadToken($formattedRepository); + $response = $repositoryManagerClient->fetchReadToken($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/fetch_read_write_token.php b/Build/samples/V2/RepositoryManagerClient/fetch_read_write_token.php index 51ca8ba3057c..9a3772b2a0c1 100644 --- a/Build/samples/V2/RepositoryManagerClient/fetch_read_write_token.php +++ b/Build/samples/V2/RepositoryManagerClient/fetch_read_write_token.php @@ -24,8 +24,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_FetchReadWriteToken_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\FetchReadWriteTokenRequest; use Google\Cloud\Build\V2\FetchReadWriteTokenResponse; -use Google\Cloud\Build\V2\RepositoryManagerClient; /** * Fetches read/write token of a given repository. @@ -39,10 +40,14 @@ function fetch_read_write_token_sample(string $formattedRepository): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new FetchReadWriteTokenRequest()) + ->setRepository($formattedRepository); + // Call the API and handle any network failures. try { /** @var FetchReadWriteTokenResponse $response */ - $response = $repositoryManagerClient->fetchReadWriteToken($formattedRepository); + $response = $repositoryManagerClient->fetchReadWriteToken($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/get_connection.php b/Build/samples/V2/RepositoryManagerClient/get_connection.php index 89ca0b8b1410..9792ba919cb0 100644 --- a/Build/samples/V2/RepositoryManagerClient/get_connection.php +++ b/Build/samples/V2/RepositoryManagerClient/get_connection.php @@ -24,8 +24,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_GetConnection_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Build\V2\Connection; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\GetConnectionRequest; /** * Gets details of a single connection. @@ -39,10 +40,14 @@ function get_connection_sample(string $formattedName): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new GetConnectionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Connection $response */ - $response = $repositoryManagerClient->getConnection($formattedName); + $response = $repositoryManagerClient->getConnection($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/get_iam_policy.php b/Build/samples/V2/RepositoryManagerClient/get_iam_policy.php index 55f48a299d5a..a9fbed2d0ef2 100644 --- a/Build/samples/V2/RepositoryManagerClient/get_iam_policy.php +++ b/Build/samples/V2/RepositoryManagerClient/get_iam_policy.php @@ -24,7 +24,8 @@ // [START cloudbuild_v2_generated_RepositoryManager_GetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Iam\V1\GetIamPolicyRequest; use Google\Cloud\Iam\V1\Policy; /** @@ -39,10 +40,14 @@ function get_iam_policy_sample(string $resource): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + // Call the API and handle any network failures. try { /** @var Policy $response */ - $response = $repositoryManagerClient->getIamPolicy($resource); + $response = $repositoryManagerClient->getIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/get_repository.php b/Build/samples/V2/RepositoryManagerClient/get_repository.php index fb7c68caef01..4020e1517ff2 100644 --- a/Build/samples/V2/RepositoryManagerClient/get_repository.php +++ b/Build/samples/V2/RepositoryManagerClient/get_repository.php @@ -24,8 +24,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_GetRepository_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\GetRepositoryRequest; use Google\Cloud\Build\V2\Repository; -use Google\Cloud\Build\V2\RepositoryManagerClient; /** * Gets details of a single repository. @@ -39,10 +40,14 @@ function get_repository_sample(string $formattedName): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new GetRepositoryRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Repository $response */ - $response = $repositoryManagerClient->getRepository($formattedName); + $response = $repositoryManagerClient->getRepository($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/list_connections.php b/Build/samples/V2/RepositoryManagerClient/list_connections.php index 00a8f81a86fc..f19df83f4226 100644 --- a/Build/samples/V2/RepositoryManagerClient/list_connections.php +++ b/Build/samples/V2/RepositoryManagerClient/list_connections.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_ListConnections_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Build\V2\Connection; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\ListConnectionsRequest; /** * Lists Connections in a given project and location. @@ -40,10 +41,14 @@ function list_connections_sample(string $formattedParent): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new ListConnectionsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->listConnections($formattedParent); + $response = $repositoryManagerClient->listConnections($request); /** @var Connection $element */ foreach ($response as $element) { diff --git a/Build/samples/V2/RepositoryManagerClient/list_repositories.php b/Build/samples/V2/RepositoryManagerClient/list_repositories.php index c78f520f6f85..0b414ecde898 100644 --- a/Build/samples/V2/RepositoryManagerClient/list_repositories.php +++ b/Build/samples/V2/RepositoryManagerClient/list_repositories.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_ListRepositories_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Build\V2\ListRepositoriesRequest; use Google\Cloud\Build\V2\Repository; -use Google\Cloud\Build\V2\RepositoryManagerClient; /** * Lists Repositories in a given connection. @@ -40,10 +41,14 @@ function list_repositories_sample(string $formattedParent): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); + // Prepare the request message. + $request = (new ListRepositoriesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->listRepositories($formattedParent); + $response = $repositoryManagerClient->listRepositories($request); /** @var Repository $element */ foreach ($response as $element) { diff --git a/Build/samples/V2/RepositoryManagerClient/set_iam_policy.php b/Build/samples/V2/RepositoryManagerClient/set_iam_policy.php index 9118eede4608..2937d2590e92 100644 --- a/Build/samples/V2/RepositoryManagerClient/set_iam_policy.php +++ b/Build/samples/V2/RepositoryManagerClient/set_iam_policy.php @@ -24,8 +24,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_SetIamPolicy_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Iam\V1\Policy; +use Google\Cloud\Iam\V1\SetIamPolicyRequest; /** * Sets the access control policy on the specified resource. Replaces @@ -42,13 +43,16 @@ function set_iam_policy_sample(string $resource): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $repositoryManagerClient->setIamPolicy($resource, $policy); + $response = $repositoryManagerClient->setIamPolicy($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/test_iam_permissions.php b/Build/samples/V2/RepositoryManagerClient/test_iam_permissions.php index 63ba941a5d86..cbad5cee2ce3 100644 --- a/Build/samples/V2/RepositoryManagerClient/test_iam_permissions.php +++ b/Build/samples/V2/RepositoryManagerClient/test_iam_permissions.php @@ -24,7 +24,8 @@ // [START cloudbuild_v2_generated_RepositoryManager_TestIamPermissions_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; +use Google\Cloud\Iam\V1\TestIamPermissionsRequest; use Google\Cloud\Iam\V1\TestIamPermissionsResponse; /** @@ -48,13 +49,16 @@ function test_iam_permissions_sample(string $resource, string $permissionsElemen // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // 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 = $repositoryManagerClient->testIamPermissions($resource, $permissions); + $response = $repositoryManagerClient->testIamPermissions($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Build/samples/V2/RepositoryManagerClient/update_connection.php b/Build/samples/V2/RepositoryManagerClient/update_connection.php index 0ac518be7fa9..423557d240e3 100644 --- a/Build/samples/V2/RepositoryManagerClient/update_connection.php +++ b/Build/samples/V2/RepositoryManagerClient/update_connection.php @@ -25,8 +25,9 @@ // [START cloudbuild_v2_generated_RepositoryManager_UpdateConnection_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; +use Google\Cloud\Build\V2\Client\RepositoryManagerClient; use Google\Cloud\Build\V2\Connection; -use Google\Cloud\Build\V2\RepositoryManagerClient; +use Google\Cloud\Build\V2\UpdateConnectionRequest; use Google\Rpc\Status; /** @@ -43,13 +44,15 @@ function update_connection_sample(): void // Create a client. $repositoryManagerClient = new RepositoryManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $connection = new Connection(); + $request = (new UpdateConnectionRequest()) + ->setConnection($connection); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $repositoryManagerClient->updateConnection($connection); + $response = $repositoryManagerClient->updateConnection($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/Build/src/V2/BatchCreateRepositoriesRequest.php b/Build/src/V2/BatchCreateRepositoriesRequest.php index 10792323370e..256d779a83ee 100644 --- a/Build/src/V2/BatchCreateRepositoriesRequest.php +++ b/Build/src/V2/BatchCreateRepositoriesRequest.php @@ -31,6 +31,25 @@ class BatchCreateRepositoriesRequest extends \Google\Protobuf\Internal\Message */ private $requests; + /** + * @param string $parent Required. The connection to contain all the repositories being created. + * Format: projects/*/locations/*/connections/* + * The parent field in the CreateRepositoryRequest messages + * must either be empty or match this field. Please see + * {@see RepositoryManagerClient::connectionName()} for help formatting this field. + * @param \Google\Cloud\Build\V2\CreateRepositoryRequest[] $requests Required. The request messages specifying the repositories to create. + * + * @return \Google\Cloud\Build\V2\BatchCreateRepositoriesRequest + * + * @experimental + */ + public static function build(string $parent, array $requests): self + { + return (new self()) + ->setParent($parent) + ->setRequests($requests); + } + /** * Constructor. * diff --git a/owl-bot-staging/Build/v2/src/V2/Client/BaseClient/RepositoryManagerBaseClient.php b/Build/src/V2/Client/BaseClient/RepositoryManagerBaseClient.php similarity index 100% rename from owl-bot-staging/Build/v2/src/V2/Client/BaseClient/RepositoryManagerBaseClient.php rename to Build/src/V2/Client/BaseClient/RepositoryManagerBaseClient.php diff --git a/owl-bot-staging/Build/v2/src/V2/Client/RepositoryManagerClient.php b/Build/src/V2/Client/RepositoryManagerClient.php similarity index 100% rename from owl-bot-staging/Build/v2/src/V2/Client/RepositoryManagerClient.php rename to Build/src/V2/Client/RepositoryManagerClient.php diff --git a/Build/src/V2/CreateConnectionRequest.php b/Build/src/V2/CreateConnectionRequest.php index f15b5ba8d08d..baf6736e2b37 100644 --- a/Build/src/V2/CreateConnectionRequest.php +++ b/Build/src/V2/CreateConnectionRequest.php @@ -38,6 +38,28 @@ class CreateConnectionRequest extends \Google\Protobuf\Internal\Message */ private $connection_id = ''; + /** + * @param string $parent Required. Project and location where the connection will be created. + * Format: `projects/*/locations/*`. Please see + * {@see RepositoryManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Build\V2\Connection $connection Required. The Connection to create. + * @param string $connectionId Required. The ID to use for the Connection, which will become the final + * component of the Connection's resource name. Names must be unique + * per-project per-location. Allows alphanumeric characters and any of + * -._~%!$&'()*+,;=@. + * + * @return \Google\Cloud\Build\V2\CreateConnectionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Build\V2\Connection $connection, string $connectionId): self + { + return (new self()) + ->setParent($parent) + ->setConnection($connection) + ->setConnectionId($connectionId); + } + /** * Constructor. * diff --git a/Build/src/V2/CreateRepositoryRequest.php b/Build/src/V2/CreateRepositoryRequest.php index 199eab7b863c..27e44315aa9b 100644 --- a/Build/src/V2/CreateRepositoryRequest.php +++ b/Build/src/V2/CreateRepositoryRequest.php @@ -39,6 +39,29 @@ class CreateRepositoryRequest extends \Google\Protobuf\Internal\Message */ private $repository_id = ''; + /** + * @param string $parent Required. The connection to contain the repository. If the request is part + * of a BatchCreateRepositoriesRequest, this field should be empty or match + * the parent specified there. Please see + * {@see RepositoryManagerClient::connectionName()} for help formatting this field. + * @param \Google\Cloud\Build\V2\Repository $repository Required. The repository to create. + * @param string $repositoryId Required. The ID to use for the repository, which will become the final + * component of the repository's resource name. This ID should be unique in + * the connection. Allows alphanumeric characters and any of + * -._~%!$&'()*+,;=@. + * + * @return \Google\Cloud\Build\V2\CreateRepositoryRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Build\V2\Repository $repository, string $repositoryId): self + { + return (new self()) + ->setParent($parent) + ->setRepository($repository) + ->setRepositoryId($repositoryId); + } + /** * Constructor. * diff --git a/Build/src/V2/DeleteConnectionRequest.php b/Build/src/V2/DeleteConnectionRequest.php index 4391af958c12..e054f29cf7e3 100644 --- a/Build/src/V2/DeleteConnectionRequest.php +++ b/Build/src/V2/DeleteConnectionRequest.php @@ -37,6 +37,21 @@ class DeleteConnectionRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. The name of the Connection to delete. + * Format: `projects/*/locations/*/connections/*`. Please see + * {@see RepositoryManagerClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\DeleteConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Build/src/V2/DeleteRepositoryRequest.php b/Build/src/V2/DeleteRepositoryRequest.php index 16dd63021190..1bb8842af7c3 100644 --- a/Build/src/V2/DeleteRepositoryRequest.php +++ b/Build/src/V2/DeleteRepositoryRequest.php @@ -37,6 +37,21 @@ class DeleteRepositoryRequest extends \Google\Protobuf\Internal\Message */ private $validate_only = false; + /** + * @param string $name Required. The name of the Repository to delete. + * Format: `projects/*/locations/*/connections/*/repositories/*`. Please see + * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\DeleteRepositoryRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Build/src/V2/FetchReadTokenRequest.php b/Build/src/V2/FetchReadTokenRequest.php index d5b9497a7079..ebd949ec1c8d 100644 --- a/Build/src/V2/FetchReadTokenRequest.php +++ b/Build/src/V2/FetchReadTokenRequest.php @@ -23,6 +23,21 @@ class FetchReadTokenRequest extends \Google\Protobuf\Internal\Message */ private $repository = ''; + /** + * @param string $repository Required. The resource name of the repository in the format + * `projects/*/locations/*/connections/*/repositories/*`. Please see + * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\FetchReadTokenRequest + * + * @experimental + */ + public static function build(string $repository): self + { + return (new self()) + ->setRepository($repository); + } + /** * Constructor. * diff --git a/Build/src/V2/FetchReadWriteTokenRequest.php b/Build/src/V2/FetchReadWriteTokenRequest.php index 42c2178d92f6..7d0ba66e6169 100644 --- a/Build/src/V2/FetchReadWriteTokenRequest.php +++ b/Build/src/V2/FetchReadWriteTokenRequest.php @@ -23,6 +23,21 @@ class FetchReadWriteTokenRequest extends \Google\Protobuf\Internal\Message */ private $repository = ''; + /** + * @param string $repository Required. The resource name of the repository in the format + * `projects/*/locations/*/connections/*/repositories/*`. Please see + * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\FetchReadWriteTokenRequest + * + * @experimental + */ + public static function build(string $repository): self + { + return (new self()) + ->setRepository($repository); + } + /** * Constructor. * diff --git a/Build/src/V2/GetConnectionRequest.php b/Build/src/V2/GetConnectionRequest.php index 6b373555e5cd..9f3a2ecfe864 100644 --- a/Build/src/V2/GetConnectionRequest.php +++ b/Build/src/V2/GetConnectionRequest.php @@ -23,6 +23,21 @@ class GetConnectionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the Connection to retrieve. + * Format: `projects/*/locations/*/connections/*`. Please see + * {@see RepositoryManagerClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\GetConnectionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Build/src/V2/GetRepositoryRequest.php b/Build/src/V2/GetRepositoryRequest.php index 2423d6742aaa..9775609531fa 100644 --- a/Build/src/V2/GetRepositoryRequest.php +++ b/Build/src/V2/GetRepositoryRequest.php @@ -23,6 +23,21 @@ class GetRepositoryRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the Repository to retrieve. + * Format: `projects/*/locations/*/connections/*/repositories/*`. Please see + * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\GetRepositoryRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/Build/src/V2/ListConnectionsRequest.php b/Build/src/V2/ListConnectionsRequest.php index b1cc2c4cea3e..d768d13cf5b9 100644 --- a/Build/src/V2/ListConnectionsRequest.php +++ b/Build/src/V2/ListConnectionsRequest.php @@ -35,6 +35,21 @@ class ListConnectionsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. The parent, which owns this collection of Connections. + * Format: `projects/*/locations/*`. Please see + * {@see RepositoryManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\ListConnectionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/Build/src/V2/ListRepositoriesRequest.php b/Build/src/V2/ListRepositoriesRequest.php index 269edf1d5e5c..61d2d1b2b0a3 100644 --- a/Build/src/V2/ListRepositoriesRequest.php +++ b/Build/src/V2/ListRepositoriesRequest.php @@ -44,6 +44,21 @@ class ListRepositoriesRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $parent Required. The parent, which owns this collection of Repositories. + * Format: `projects/*/locations/*/connections/*`. Please see + * {@see RepositoryManagerClient::connectionName()} for help formatting this field. + * + * @return \Google\Cloud\Build\V2\ListRepositoriesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/Build/src/V2/UpdateConnectionRequest.php b/Build/src/V2/UpdateConnectionRequest.php index 300c94011b6e..40ee2ccbd838 100644 --- a/Build/src/V2/UpdateConnectionRequest.php +++ b/Build/src/V2/UpdateConnectionRequest.php @@ -46,6 +46,21 @@ class UpdateConnectionRequest extends \Google\Protobuf\Internal\Message */ private $etag = ''; + /** + * @param \Google\Cloud\Build\V2\Connection $connection Required. The Connection to update. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * + * @return \Google\Cloud\Build\V2\UpdateConnectionRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Build\V2\Connection $connection, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setConnection($connection) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/Build/src/V2/resources/repository_manager_descriptor_config.php b/Build/src/V2/resources/repository_manager_descriptor_config.php index 73fcb4ef9f46..ede8e43a278f 100644 --- a/Build/src/V2/resources/repository_manager_descriptor_config.php +++ b/Build/src/V2/resources/repository_manager_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateConnection' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateRepository' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteConnection' => [ 'longRunning' => [ @@ -42,6 +69,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteRepository' => [ 'longRunning' => [ @@ -52,6 +88,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateConnection' => [ 'longRunning' => [ @@ -62,6 +107,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'connection.name', + 'fieldAccessors' => [ + 'getConnection', + 'getName', + ], + ], + ], ], 'FetchLinkableRepositories' => [ 'pageStreaming' => [ @@ -72,6 +127,64 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getRepositories', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Build\V2\FetchLinkableRepositoriesResponse', + 'headerParams' => [ + [ + 'keyName' => 'connection', + 'fieldAccessors' => [ + 'getConnection', + ], + ], + ], + ], + 'FetchReadToken' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Build\V2\FetchReadTokenResponse', + 'headerParams' => [ + [ + 'keyName' => 'repository', + 'fieldAccessors' => [ + 'getRepository', + ], + ], + ], + ], + 'FetchReadWriteToken' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Build\V2\FetchReadWriteTokenResponse', + 'headerParams' => [ + [ + 'keyName' => 'repository', + 'fieldAccessors' => [ + 'getRepository', + ], + ], + ], + ], + 'GetConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Build\V2\Connection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetRepository' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Build\V2\Repository', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListConnections' => [ 'pageStreaming' => [ @@ -82,6 +195,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getConnections', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Build\V2\ListConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListRepositories' => [ 'pageStreaming' => [ @@ -92,16 +215,63 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getRepositories', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Build\V2\ListRepositoriesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], 'interfaceOverride' => 'google.iam.v1.IAMPolicy', ], + 'templateMap' => [ + 'connection' => 'projects/{project}/locations/{location}/connections/{connection}', + 'location' => 'projects/{project}/locations/{location}', + 'repository' => 'projects/{project}/locations/{location}/connections/{connection}/repositories/{repository}', + 'secretVersion' => 'projects/{project}/secrets/{secret}/versions/{version}', + 'service' => 'projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}', + ], ], ], ]; diff --git a/owl-bot-staging/Build/v2/tests/Unit/V2/Client/RepositoryManagerClientTest.php b/Build/tests/Unit/V2/Client/RepositoryManagerClientTest.php similarity index 100% rename from owl-bot-staging/Build/v2/tests/Unit/V2/Client/RepositoryManagerClientTest.php rename to Build/tests/Unit/V2/Client/RepositoryManagerClientTest.php diff --git a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate.php b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate.php index ee7aaf2d6aad..461884c10e74 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\CertificateManager\V1\Certificate; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\CreateCertificateRequest; use Google\Rpc\Status; /** @@ -42,17 +43,17 @@ function create_certificate_sample(string $formattedParent, string $certificateI // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificate = new Certificate(); + $request = (new CreateCertificateRequest()) + ->setParent($formattedParent) + ->setCertificateId($certificateId) + ->setCertificate($certificate); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificate( - $formattedParent, - $certificateId, - $certificate - ); + $response = $certificateManagerClient->createCertificate($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php index 615ee32a187e..7ba1a7de1bdc 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php @@ -28,7 +28,8 @@ use Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig; use Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig; use Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\KeyAlgorithm; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\CreateCertificateIssuanceConfigRequest; use Google\Protobuf\Duration; use Google\Rpc\Status; @@ -53,7 +54,7 @@ function create_certificate_issuance_config_sample( // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificateIssuanceConfigCertificateAuthorityConfig = new CertificateAuthorityConfig(); $certificateIssuanceConfigLifetime = new Duration(); $certificateIssuanceConfig = (new CertificateIssuanceConfig()) @@ -61,15 +62,15 @@ function create_certificate_issuance_config_sample( ->setLifetime($certificateIssuanceConfigLifetime) ->setRotationWindowPercentage($certificateIssuanceConfigRotationWindowPercentage) ->setKeyAlgorithm($certificateIssuanceConfigKeyAlgorithm); + $request = (new CreateCertificateIssuanceConfigRequest()) + ->setParent($formattedParent) + ->setCertificateIssuanceConfigId($certificateIssuanceConfigId) + ->setCertificateIssuanceConfig($certificateIssuanceConfig); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateIssuanceConfig( - $formattedParent, - $certificateIssuanceConfigId, - $certificateIssuanceConfig - ); + $response = $certificateManagerClient->createCertificateIssuanceConfig($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map.php b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map.php index 0f79f2cf1e3e..409405131e89 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_CreateCertificateMap_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMap; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\CreateCertificateMapRequest; use Google\Rpc\Status; /** @@ -42,17 +43,17 @@ function create_certificate_map_sample(string $formattedParent, string $certific // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificateMap = new CertificateMap(); + $request = (new CreateCertificateMapRequest()) + ->setParent($formattedParent) + ->setCertificateMapId($certificateMapId) + ->setCertificateMap($certificateMap); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateMap( - $formattedParent, - $certificateMapId, - $certificateMap - ); + $response = $certificateManagerClient->createCertificateMap($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map_entry.php b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map_entry.php index 2419b1d2b82a..a3017b79ab1f 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map_entry.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/create_certificate_map_entry.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_CreateCertificateMapEntry_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMapEntry; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\CreateCertificateMapEntryRequest; use Google\Rpc\Status; /** @@ -44,17 +45,17 @@ function create_certificate_map_entry_sample( // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificateMapEntry = new CertificateMapEntry(); + $request = (new CreateCertificateMapEntryRequest()) + ->setParent($formattedParent) + ->setCertificateMapEntryId($certificateMapEntryId) + ->setCertificateMapEntry($certificateMapEntry); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateMapEntry( - $formattedParent, - $certificateMapEntryId, - $certificateMapEntry - ); + $response = $certificateManagerClient->createCertificateMapEntry($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/create_dns_authorization.php b/CertificateManager/samples/V1/CertificateManagerClient/create_dns_authorization.php index 924da713c22e..2b32506b54e3 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/create_dns_authorization.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/create_dns_authorization.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_CreateDnsAuthorization_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\CreateDnsAuthorizationRequest; use Google\Cloud\CertificateManager\V1\DnsAuthorization; use Google\Rpc\Status; @@ -49,18 +50,18 @@ function create_dns_authorization_sample( // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dnsAuthorization = (new DnsAuthorization()) ->setDomain($dnsAuthorizationDomain); + $request = (new CreateDnsAuthorizationRequest()) + ->setParent($formattedParent) + ->setDnsAuthorizationId($dnsAuthorizationId) + ->setDnsAuthorization($dnsAuthorization); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->createDnsAuthorization( - $formattedParent, - $dnsAuthorizationId, - $dnsAuthorization - ); + $response = $certificateManagerClient->createDnsAuthorization($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate.php b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate.php index 77c5fdf14860..f2cc2c517a49 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_DeleteCertificate_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\DeleteCertificateRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_certificate_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new DeleteCertificateRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificate($formattedName); + $response = $certificateManagerClient->deleteCertificate($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php index ab829019fb61..b4eed09913ae 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_DeleteCertificateIssuanceConfig_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\DeleteCertificateIssuanceConfigRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_certificate_issuance_config_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new DeleteCertificateIssuanceConfigRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateIssuanceConfig($formattedName); + $response = $certificateManagerClient->deleteCertificateIssuanceConfig($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map.php b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map.php index b9236888ba6b..4558b3dd5c84 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_DeleteCertificateMap_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\DeleteCertificateMapRequest; use Google\Rpc\Status; /** @@ -42,10 +43,14 @@ function delete_certificate_map_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new DeleteCertificateMapRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateMap($formattedName); + $response = $certificateManagerClient->deleteCertificateMap($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php index af251c5895a8..921ae1661298 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_DeleteCertificateMapEntry_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\DeleteCertificateMapEntryRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_certificate_map_entry_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new DeleteCertificateMapEntryRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateMapEntry($formattedName); + $response = $certificateManagerClient->deleteCertificateMapEntry($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/delete_dns_authorization.php b/CertificateManager/samples/V1/CertificateManagerClient/delete_dns_authorization.php index 2fe20b1c850b..be1583059577 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/delete_dns_authorization.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/delete_dns_authorization.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_DeleteDnsAuthorization_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\DeleteDnsAuthorizationRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_dns_authorization_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new DeleteDnsAuthorizationRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteDnsAuthorization($formattedName); + $response = $certificateManagerClient->deleteDnsAuthorization($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate.php b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate.php index 90cbfcc97475..8e3b21d8c656 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_GetCertificate_sync] use Google\ApiCore\ApiException; use Google\Cloud\CertificateManager\V1\Certificate; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\GetCertificateRequest; /** * Gets details of a single Certificate. @@ -39,10 +40,14 @@ function get_certificate_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new GetCertificateRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Certificate $response */ - $response = $certificateManagerClient->getCertificate($formattedName); + $response = $certificateManagerClient->getCertificate($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php index 0f766bb9fa26..b38265363c8e 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_GetCertificateIssuanceConfig_sync] use Google\ApiCore\ApiException; use Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\GetCertificateIssuanceConfigRequest; /** * Gets details of a single CertificateIssuanceConfig. @@ -39,10 +40,14 @@ function get_certificate_issuance_config_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new GetCertificateIssuanceConfigRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var CertificateIssuanceConfig $response */ - $response = $certificateManagerClient->getCertificateIssuanceConfig($formattedName); + $response = $certificateManagerClient->getCertificateIssuanceConfig($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map.php b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map.php index 50edaf603958..b3232e3b49cd 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map.php @@ -24,8 +24,9 @@ // [START certificatemanager_v1_generated_CertificateManager_GetCertificateMap_sync] use Google\ApiCore\ApiException; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMap; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\GetCertificateMapRequest; /** * Gets details of a single CertificateMap. @@ -39,10 +40,14 @@ function get_certificate_map_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new GetCertificateMapRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var CertificateMap $response */ - $response = $certificateManagerClient->getCertificateMap($formattedName); + $response = $certificateManagerClient->getCertificateMap($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map_entry.php b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map_entry.php index fe3c58338dab..1399106ea7f1 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map_entry.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_certificate_map_entry.php @@ -24,8 +24,9 @@ // [START certificatemanager_v1_generated_CertificateManager_GetCertificateMapEntry_sync] use Google\ApiCore\ApiException; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMapEntry; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\GetCertificateMapEntryRequest; /** * Gets details of a single CertificateMapEntry. @@ -39,10 +40,14 @@ function get_certificate_map_entry_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new GetCertificateMapEntryRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var CertificateMapEntry $response */ - $response = $certificateManagerClient->getCertificateMapEntry($formattedName); + $response = $certificateManagerClient->getCertificateMapEntry($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_dns_authorization.php b/CertificateManager/samples/V1/CertificateManagerClient/get_dns_authorization.php index 6a17f2e72255..fd836cd89056 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_dns_authorization.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_dns_authorization.php @@ -24,8 +24,9 @@ // [START certificatemanager_v1_generated_CertificateManager_GetDnsAuthorization_sync] use Google\ApiCore\ApiException; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\DnsAuthorization; +use Google\Cloud\CertificateManager\V1\GetDnsAuthorizationRequest; /** * Gets details of a single DnsAuthorization. @@ -39,10 +40,14 @@ function get_dns_authorization_sample(string $formattedName): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new GetDnsAuthorizationRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var DnsAuthorization $response */ - $response = $certificateManagerClient->getDnsAuthorization($formattedName); + $response = $certificateManagerClient->getDnsAuthorization($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/get_location.php b/CertificateManager/samples/V1/CertificateManagerClient/get_location.php index a3e8350d2bf6..b5b03ab1d01b 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/get_location.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/get_location.php @@ -24,7 +24,8 @@ // [START certificatemanager_v1_generated_CertificateManager_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $certificateManagerClient->getLocation(); + $response = $certificateManagerClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php index dfc60f117a0b..5efdfcfa1214 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsRequest; /** * Lists CertificateIssuanceConfigs in a given project and location. @@ -40,10 +41,14 @@ function list_certificate_issuance_configs_sample(string $formattedParent): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new ListCertificateIssuanceConfigsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateIssuanceConfigs($formattedParent); + $response = $certificateManagerClient->listCertificateIssuanceConfigs($request); /** @var CertificateIssuanceConfig $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_map_entries.php b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_map_entries.php index 96bcfc3b764f..cae0f6e6a36f 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_map_entries.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_map_entries.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_ListCertificateMapEntries_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMapEntry; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesRequest; /** * Lists CertificateMapEntries in a given project and location. @@ -41,10 +42,14 @@ function list_certificate_map_entries_sample(string $formattedParent): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new ListCertificateMapEntriesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateMapEntries($formattedParent); + $response = $certificateManagerClient->listCertificateMapEntries($request); /** @var CertificateMapEntry $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_maps.php b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_maps.php index bd65a4358b2c..2cb9837352d8 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_maps.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_certificate_maps.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_ListCertificateMaps_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMap; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\ListCertificateMapsRequest; /** * Lists CertificateMaps in a given project and location. @@ -40,10 +41,14 @@ function list_certificate_maps_sample(string $formattedParent): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new ListCertificateMapsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateMaps($formattedParent); + $response = $certificateManagerClient->listCertificateMaps($request); /** @var CertificateMap $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_certificates.php b/CertificateManager/samples/V1/CertificateManagerClient/list_certificates.php index bd55163dd80c..11c9925841f1 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_certificates.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_certificates.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\CertificateManager\V1\Certificate; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\ListCertificatesRequest; /** * Lists Certificates in a given project and location. @@ -40,10 +41,14 @@ function list_certificates_sample(string $formattedParent): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new ListCertificatesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificates($formattedParent); + $response = $certificateManagerClient->listCertificates($request); /** @var Certificate $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_dns_authorizations.php b/CertificateManager/samples/V1/CertificateManagerClient/list_dns_authorizations.php index 03c078e604e5..e1ad2500bb21 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_dns_authorizations.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_dns_authorizations.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_ListDnsAuthorizations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\DnsAuthorization; +use Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsRequest; /** * Lists DnsAuthorizations in a given project and location. @@ -40,10 +41,14 @@ function list_dns_authorizations_sample(string $formattedParent): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = (new ListDnsAuthorizationsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listDnsAuthorizations($formattedParent); + $response = $certificateManagerClient->listDnsAuthorizations($request); /** @var DnsAuthorization $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/list_locations.php b/CertificateManager/samples/V1/CertificateManagerClient/list_locations.php index f966e471d87d..38df92f927ed 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/list_locations.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/list_locations.php @@ -25,7 +25,8 @@ // [START certificatemanager_v1_generated_CertificateManager_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listLocations(); + $response = $certificateManagerClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate.php b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate.php index 4b7956dc8ca3..01ae92819950 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\CertificateManager\V1\Certificate; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\UpdateCertificateRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -44,14 +45,17 @@ function update_certificate_sample(): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificate = new Certificate(); $updateMask = new FieldMask(); + $request = (new UpdateCertificateRequest()) + ->setCertificate($certificate) + ->setUpdateMask($updateMask); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificate($certificate, $updateMask); + $response = $certificateManagerClient->updateCertificate($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map.php b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map.php index f64ff47edae9..718d913df19d 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_UpdateCertificateMap_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMap; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\UpdateCertificateMapRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -44,14 +45,17 @@ function update_certificate_map_sample(): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificateMap = new CertificateMap(); $updateMask = new FieldMask(); + $request = (new UpdateCertificateMapRequest()) + ->setCertificateMap($certificateMap) + ->setUpdateMask($updateMask); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificateMap($certificateMap, $updateMask); + $response = $certificateManagerClient->updateCertificateMap($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map_entry.php b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map_entry.php index 9fabae5596c3..3f09d0ba7b0d 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map_entry.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/update_certificate_map_entry.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_UpdateCertificateMapEntry_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\CertificateMapEntry; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\UpdateCertificateMapEntryRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -44,14 +45,17 @@ function update_certificate_map_entry_sample(): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $certificateMapEntry = new CertificateMapEntry(); $updateMask = new FieldMask(); + $request = (new UpdateCertificateMapEntryRequest()) + ->setCertificateMapEntry($certificateMapEntry) + ->setUpdateMask($updateMask); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificateMapEntry($certificateMapEntry, $updateMask); + $response = $certificateManagerClient->updateCertificateMapEntry($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/CertificateManager/samples/V1/CertificateManagerClient/update_dns_authorization.php b/CertificateManager/samples/V1/CertificateManagerClient/update_dns_authorization.php index 28e38a3b3800..f842db852d8c 100644 --- a/CertificateManager/samples/V1/CertificateManagerClient/update_dns_authorization.php +++ b/CertificateManager/samples/V1/CertificateManagerClient/update_dns_authorization.php @@ -25,8 +25,9 @@ // [START certificatemanager_v1_generated_CertificateManager_UpdateDnsAuthorization_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\CertificateManager\V1\CertificateManagerClient; +use Google\Cloud\CertificateManager\V1\Client\CertificateManagerClient; use Google\Cloud\CertificateManager\V1\DnsAuthorization; +use Google\Cloud\CertificateManager\V1\UpdateDnsAuthorizationRequest; use Google\Protobuf\FieldMask; use Google\Rpc\Status; @@ -43,15 +44,18 @@ function update_dns_authorization_sample(string $dnsAuthorizationDomain): void // Create a client. $certificateManagerClient = new CertificateManagerClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dnsAuthorization = (new DnsAuthorization()) ->setDomain($dnsAuthorizationDomain); $updateMask = new FieldMask(); + $request = (new UpdateDnsAuthorizationRequest()) + ->setDnsAuthorization($dnsAuthorization) + ->setUpdateMask($updateMask); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateDnsAuthorization($dnsAuthorization, $updateMask); + $response = $certificateManagerClient->updateDnsAuthorization($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/Client/BaseClient/CertificateManagerBaseClient.php b/CertificateManager/src/V1/Client/BaseClient/CertificateManagerBaseClient.php similarity index 100% rename from owl-bot-staging/CertificateManager/v1/src/V1/Client/BaseClient/CertificateManagerBaseClient.php rename to CertificateManager/src/V1/Client/BaseClient/CertificateManagerBaseClient.php diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/Client/CertificateManagerClient.php b/CertificateManager/src/V1/Client/CertificateManagerClient.php similarity index 100% rename from owl-bot-staging/CertificateManager/v1/src/V1/Client/CertificateManagerClient.php rename to CertificateManager/src/V1/Client/CertificateManagerClient.php diff --git a/CertificateManager/src/V1/CreateCertificateIssuanceConfigRequest.php b/CertificateManager/src/V1/CreateCertificateIssuanceConfigRequest.php index 9cce6e3fc6af..ccdee7f3640c 100644 --- a/CertificateManager/src/V1/CreateCertificateIssuanceConfigRequest.php +++ b/CertificateManager/src/V1/CreateCertificateIssuanceConfigRequest.php @@ -35,6 +35,25 @@ class CreateCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\M */ private $certificate_issuance_config = null; + /** + * @param string $parent Required. The parent resource of the certificate issuance config. Must be + * in the format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $certificateIssuanceConfig Required. A definition of the certificate issuance config to create. + * @param string $certificateIssuanceConfigId Required. A user-provided name of the certificate config. + * + * @return \Google\Cloud\CertificateManager\V1\CreateCertificateIssuanceConfigRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $certificateIssuanceConfig, string $certificateIssuanceConfigId): self + { + return (new self()) + ->setParent($parent) + ->setCertificateIssuanceConfig($certificateIssuanceConfig) + ->setCertificateIssuanceConfigId($certificateIssuanceConfigId); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/CreateCertificateMapEntryRequest.php b/CertificateManager/src/V1/CreateCertificateMapEntryRequest.php index 5ab44b777851..41e0cbb5fa7f 100644 --- a/CertificateManager/src/V1/CreateCertificateMapEntryRequest.php +++ b/CertificateManager/src/V1/CreateCertificateMapEntryRequest.php @@ -35,6 +35,25 @@ class CreateCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message */ private $certificate_map_entry = null; + /** + * @param string $parent Required. The parent resource of the certificate map entry. Must be in the + * format `projects/*/locations/*/certificateMaps/*`. Please see + * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. + * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create. + * @param string $certificateMapEntryId Required. A user-provided name of the certificate map entry. + * + * @return \Google\Cloud\CertificateManager\V1\CreateCertificateMapEntryRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry, string $certificateMapEntryId): self + { + return (new self()) + ->setParent($parent) + ->setCertificateMapEntry($certificateMapEntry) + ->setCertificateMapEntryId($certificateMapEntryId); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/CreateCertificateMapRequest.php b/CertificateManager/src/V1/CreateCertificateMapRequest.php index 7ef0d49f64c5..ae5fce3267b7 100644 --- a/CertificateManager/src/V1/CreateCertificateMapRequest.php +++ b/CertificateManager/src/V1/CreateCertificateMapRequest.php @@ -35,6 +35,25 @@ class CreateCertificateMapRequest extends \Google\Protobuf\Internal\Message */ private $certificate_map = null; + /** + * @param string $parent Required. The parent resource of the certificate map. Must be in the format + * `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap Required. A definition of the certificate map to create. + * @param string $certificateMapId Required. A user-provided name of the certificate map. + * + * @return \Google\Cloud\CertificateManager\V1\CreateCertificateMapRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap, string $certificateMapId): self + { + return (new self()) + ->setParent($parent) + ->setCertificateMap($certificateMap) + ->setCertificateMapId($certificateMapId); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/CreateCertificateRequest.php b/CertificateManager/src/V1/CreateCertificateRequest.php index cb0fb956853a..d13ee9f5a5d3 100644 --- a/CertificateManager/src/V1/CreateCertificateRequest.php +++ b/CertificateManager/src/V1/CreateCertificateRequest.php @@ -35,6 +35,25 @@ class CreateCertificateRequest extends \Google\Protobuf\Internal\Message */ private $certificate = null; + /** + * @param string $parent Required. The parent resource of the certificate. Must be in the format + * `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\CertificateManager\V1\Certificate $certificate Required. A definition of the certificate to create. + * @param string $certificateId Required. A user-provided name of the certificate. + * + * @return \Google\Cloud\CertificateManager\V1\CreateCertificateRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\CertificateManager\V1\Certificate $certificate, string $certificateId): self + { + return (new self()) + ->setParent($parent) + ->setCertificate($certificate) + ->setCertificateId($certificateId); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/CreateDnsAuthorizationRequest.php b/CertificateManager/src/V1/CreateDnsAuthorizationRequest.php index 957869a7181f..938be19117ed 100644 --- a/CertificateManager/src/V1/CreateDnsAuthorizationRequest.php +++ b/CertificateManager/src/V1/CreateDnsAuthorizationRequest.php @@ -35,6 +35,25 @@ class CreateDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message */ private $dns_authorization = null; + /** + * @param string $parent Required. The parent resource of the dns authorization. Must be in the + * format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to create. + * @param string $dnsAuthorizationId Required. A user-provided name of the dns authorization. + * + * @return \Google\Cloud\CertificateManager\V1\CreateDnsAuthorizationRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization, string $dnsAuthorizationId): self + { + return (new self()) + ->setParent($parent) + ->setDnsAuthorization($dnsAuthorization) + ->setDnsAuthorizationId($dnsAuthorizationId); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/DeleteCertificateIssuanceConfigRequest.php b/CertificateManager/src/V1/DeleteCertificateIssuanceConfigRequest.php index 84ea17d45188..ab71b300ca0b 100644 --- a/CertificateManager/src/V1/DeleteCertificateIssuanceConfigRequest.php +++ b/CertificateManager/src/V1/DeleteCertificateIssuanceConfigRequest.php @@ -23,6 +23,21 @@ class DeleteCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\M */ private $name = ''; + /** + * @param string $name Required. A name of the certificate issuance config to delete. Must be in + * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. Please see + * {@see CertificateManagerClient::certificateIssuanceConfigName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateIssuanceConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/DeleteCertificateMapEntryRequest.php b/CertificateManager/src/V1/DeleteCertificateMapEntryRequest.php index 78e322841f5f..9c86fa3e3a5e 100644 --- a/CertificateManager/src/V1/DeleteCertificateMapEntryRequest.php +++ b/CertificateManager/src/V1/DeleteCertificateMapEntryRequest.php @@ -23,6 +23,21 @@ class DeleteCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate map entry to delete. Must be in the + * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. Please see + * {@see CertificateManagerClient::certificateMapEntryName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateMapEntryRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/DeleteCertificateMapRequest.php b/CertificateManager/src/V1/DeleteCertificateMapRequest.php index 1da24c497f36..3223041cd941 100644 --- a/CertificateManager/src/V1/DeleteCertificateMapRequest.php +++ b/CertificateManager/src/V1/DeleteCertificateMapRequest.php @@ -23,6 +23,21 @@ class DeleteCertificateMapRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate map to delete. Must be in the format + * `projects/*/locations/*/certificateMaps/*`. Please see + * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateMapRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/DeleteCertificateRequest.php b/CertificateManager/src/V1/DeleteCertificateRequest.php index e6ddc0b1c692..7d3f8143b5e5 100644 --- a/CertificateManager/src/V1/DeleteCertificateRequest.php +++ b/CertificateManager/src/V1/DeleteCertificateRequest.php @@ -23,6 +23,21 @@ class DeleteCertificateRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate to delete. Must be in the format + * `projects/*/locations/*/certificates/*`. Please see + * {@see CertificateManagerClient::certificateName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/DeleteDnsAuthorizationRequest.php b/CertificateManager/src/V1/DeleteDnsAuthorizationRequest.php index e39f73565874..e4779ba28807 100644 --- a/CertificateManager/src/V1/DeleteDnsAuthorizationRequest.php +++ b/CertificateManager/src/V1/DeleteDnsAuthorizationRequest.php @@ -23,6 +23,21 @@ class DeleteDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the dns authorization to delete. Must be in the format + * `projects/*/locations/*/dnsAuthorizations/*`. Please see + * {@see CertificateManagerClient::dnsAuthorizationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\DeleteDnsAuthorizationRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/GetCertificateIssuanceConfigRequest.php b/CertificateManager/src/V1/GetCertificateIssuanceConfigRequest.php index a77d3b73ab95..1261e71cbea7 100644 --- a/CertificateManager/src/V1/GetCertificateIssuanceConfigRequest.php +++ b/CertificateManager/src/V1/GetCertificateIssuanceConfigRequest.php @@ -23,6 +23,21 @@ class GetCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\Mess */ private $name = ''; + /** + * @param string $name Required. A name of the certificate issuance config to describe. Must be in + * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. Please see + * {@see CertificateManagerClient::certificateIssuanceConfigName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\GetCertificateIssuanceConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/GetCertificateMapEntryRequest.php b/CertificateManager/src/V1/GetCertificateMapEntryRequest.php index ddfcc4f57c7c..9ed5855bede2 100644 --- a/CertificateManager/src/V1/GetCertificateMapEntryRequest.php +++ b/CertificateManager/src/V1/GetCertificateMapEntryRequest.php @@ -23,6 +23,21 @@ class GetCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate map entry to describe. Must be in the + * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. Please see + * {@see CertificateManagerClient::certificateMapEntryName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\GetCertificateMapEntryRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/GetCertificateMapRequest.php b/CertificateManager/src/V1/GetCertificateMapRequest.php index ecdcebac8622..d6b285b40dd2 100644 --- a/CertificateManager/src/V1/GetCertificateMapRequest.php +++ b/CertificateManager/src/V1/GetCertificateMapRequest.php @@ -23,6 +23,21 @@ class GetCertificateMapRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate map to describe. Must be in the format + * `projects/*/locations/*/certificateMaps/*`. Please see + * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\GetCertificateMapRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/GetCertificateRequest.php b/CertificateManager/src/V1/GetCertificateRequest.php index fb6c1fa811c6..666b07566966 100644 --- a/CertificateManager/src/V1/GetCertificateRequest.php +++ b/CertificateManager/src/V1/GetCertificateRequest.php @@ -23,6 +23,21 @@ class GetCertificateRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the certificate to describe. Must be in the format + * `projects/*/locations/*/certificates/*`. Please see + * {@see CertificateManagerClient::certificateName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\GetCertificateRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/GetDnsAuthorizationRequest.php b/CertificateManager/src/V1/GetDnsAuthorizationRequest.php index ce136e92fb9e..ce2f0291c6a2 100644 --- a/CertificateManager/src/V1/GetDnsAuthorizationRequest.php +++ b/CertificateManager/src/V1/GetDnsAuthorizationRequest.php @@ -23,6 +23,21 @@ class GetDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. A name of the dns authorization to describe. Must be in the + * format `projects/*/locations/*/dnsAuthorizations/*`. Please see + * {@see CertificateManagerClient::dnsAuthorizationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\GetDnsAuthorizationRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/ListCertificateIssuanceConfigsRequest.php b/CertificateManager/src/V1/ListCertificateIssuanceConfigsRequest.php index 652eebdb5327..b29b743373ce 100644 --- a/CertificateManager/src/V1/ListCertificateIssuanceConfigsRequest.php +++ b/CertificateManager/src/V1/ListCertificateIssuanceConfigsRequest.php @@ -52,6 +52,21 @@ class ListCertificateIssuanceConfigsRequest extends \Google\Protobuf\Internal\Me */ private $order_by = ''; + /** + * @param string $parent Required. The project and location from which the certificate should be + * listed, specified in the format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/ListCertificateMapEntriesRequest.php b/CertificateManager/src/V1/ListCertificateMapEntriesRequest.php index 57e00544fd4a..957ed7e760d6 100644 --- a/CertificateManager/src/V1/ListCertificateMapEntriesRequest.php +++ b/CertificateManager/src/V1/ListCertificateMapEntriesRequest.php @@ -56,6 +56,22 @@ class ListCertificateMapEntriesRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The project, location and certificate map from which the + * certificate map entries should be listed, specified in the format + * `projects/*/locations/*/certificateMaps/*`. Please see + * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/ListCertificateMapsRequest.php b/CertificateManager/src/V1/ListCertificateMapsRequest.php index b8ed892a7b71..b79b44a294bf 100644 --- a/CertificateManager/src/V1/ListCertificateMapsRequest.php +++ b/CertificateManager/src/V1/ListCertificateMapsRequest.php @@ -51,6 +51,21 @@ class ListCertificateMapsRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The project and location from which the certificate maps should + * be listed, specified in the format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\ListCertificateMapsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/ListCertificatesRequest.php b/CertificateManager/src/V1/ListCertificatesRequest.php index 9194c57628fa..8f7d2f6ca494 100644 --- a/CertificateManager/src/V1/ListCertificatesRequest.php +++ b/CertificateManager/src/V1/ListCertificatesRequest.php @@ -51,6 +51,21 @@ class ListCertificatesRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The project and location from which the certificate should be + * listed, specified in the format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\ListCertificatesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/ListDnsAuthorizationsRequest.php b/CertificateManager/src/V1/ListDnsAuthorizationsRequest.php index 45b1b68c3315..b0fba8c1af48 100644 --- a/CertificateManager/src/V1/ListDnsAuthorizationsRequest.php +++ b/CertificateManager/src/V1/ListDnsAuthorizationsRequest.php @@ -51,6 +51,21 @@ class ListDnsAuthorizationsRequest extends \Google\Protobuf\Internal\Message */ private $order_by = ''; + /** + * @param string $parent Required. The project and location from which the dns authorizations should + * be listed, specified in the format `projects/*/locations/*`. Please see + * {@see CertificateManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/UpdateCertificateMapEntryRequest.php b/CertificateManager/src/V1/UpdateCertificateMapEntryRequest.php index 2e89b3b2ea2f..29b69c45fe7a 100644 --- a/CertificateManager/src/V1/UpdateCertificateMapEntryRequest.php +++ b/CertificateManager/src/V1/UpdateCertificateMapEntryRequest.php @@ -30,6 +30,23 @@ class UpdateCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create map entry. + * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` + * definition, see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. + * + * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateMapEntryRequest + * + * @experimental + */ + public static function build(\Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificateMapEntry($certificateMapEntry) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/UpdateCertificateMapRequest.php b/CertificateManager/src/V1/UpdateCertificateMapRequest.php index 8b938c701306..f5c894c88324 100644 --- a/CertificateManager/src/V1/UpdateCertificateMapRequest.php +++ b/CertificateManager/src/V1/UpdateCertificateMapRequest.php @@ -30,6 +30,23 @@ class UpdateCertificateMapRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap Required. A definition of the certificate map to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` + * definition, see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. + * + * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateMapRequest + * + * @experimental + */ + public static function build(\Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificateMap($certificateMap) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/UpdateCertificateRequest.php b/CertificateManager/src/V1/UpdateCertificateRequest.php index 5b2e0d0bba85..6e6a9043a1ce 100644 --- a/CertificateManager/src/V1/UpdateCertificateRequest.php +++ b/CertificateManager/src/V1/UpdateCertificateRequest.php @@ -30,6 +30,23 @@ class UpdateCertificateRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\CertificateManager\V1\Certificate $certificate Required. A definition of the certificate to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` + * definition, see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. + * + * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateRequest + * + * @experimental + */ + public static function build(\Google\Cloud\CertificateManager\V1\Certificate $certificate, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificate($certificate) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/UpdateDnsAuthorizationRequest.php b/CertificateManager/src/V1/UpdateDnsAuthorizationRequest.php index 0515eaaf653c..6308c2564f12 100644 --- a/CertificateManager/src/V1/UpdateDnsAuthorizationRequest.php +++ b/CertificateManager/src/V1/UpdateDnsAuthorizationRequest.php @@ -30,6 +30,23 @@ class UpdateDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to update. + * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` + * definition, see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. + * + * @return \Google\Cloud\CertificateManager\V1\UpdateDnsAuthorizationRequest + * + * @experimental + */ + public static function build(\Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDnsAuthorization($dnsAuthorization) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/CertificateManager/src/V1/resources/certificate_manager_descriptor_config.php b/CertificateManager/src/V1/resources/certificate_manager_descriptor_config.php index db80ff631192..ae4523289cd3 100644 --- a/CertificateManager/src/V1/resources/certificate_manager_descriptor_config.php +++ b/CertificateManager/src/V1/resources/certificate_manager_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateCertificateIssuanceConfig' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateCertificateMap' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateCertificateMapEntry' => [ 'longRunning' => [ @@ -42,6 +69,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'CreateDnsAuthorization' => [ 'longRunning' => [ @@ -52,6 +88,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteCertificate' => [ 'longRunning' => [ @@ -62,6 +107,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteCertificateIssuanceConfig' => [ 'longRunning' => [ @@ -72,6 +126,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteCertificateMap' => [ 'longRunning' => [ @@ -82,6 +145,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteCertificateMapEntry' => [ 'longRunning' => [ @@ -92,6 +164,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteDnsAuthorization' => [ 'longRunning' => [ @@ -102,6 +183,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateCertificate' => [ 'longRunning' => [ @@ -112,6 +202,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate.name', + 'fieldAccessors' => [ + 'getCertificate', + 'getName', + ], + ], + ], ], 'UpdateCertificateMap' => [ 'longRunning' => [ @@ -122,6 +222,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate_map.name', + 'fieldAccessors' => [ + 'getCertificateMap', + 'getName', + ], + ], + ], ], 'UpdateCertificateMapEntry' => [ 'longRunning' => [ @@ -132,6 +242,16 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate_map_entry.name', + 'fieldAccessors' => [ + 'getCertificateMapEntry', + 'getName', + ], + ], + ], ], 'UpdateDnsAuthorization' => [ 'longRunning' => [ @@ -142,6 +262,76 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'dns_authorization.name', + 'fieldAccessors' => [ + 'getDnsAuthorization', + 'getName', + ], + ], + ], + ], + 'GetCertificate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\Certificate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateIssuanceConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateMap' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateMap', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateMapEntry' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateMapEntry', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDnsAuthorization' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\DnsAuthorization', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListCertificateIssuanceConfigs' => [ 'pageStreaming' => [ @@ -152,6 +342,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getCertificateIssuanceConfigs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListCertificateMapEntries' => [ 'pageStreaming' => [ @@ -162,6 +362,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getCertificateMapEntries', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListCertificateMaps' => [ 'pageStreaming' => [ @@ -172,6 +382,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getCertificateMaps', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateMapsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListCertificates' => [ 'pageStreaming' => [ @@ -182,6 +402,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getCertificates', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificatesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListDnsAuthorizations' => [ 'pageStreaming' => [ @@ -192,8 +422,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDnsAuthorizations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -205,8 +455,27 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], + 'templateMap' => [ + 'caPool' => 'projects/{project}/locations/{location}/caPools/{ca_pool}', + 'certificate' => 'projects/{project}/locations/{location}/certificates/{certificate}', + 'certificateIssuanceConfig' => 'projects/{project}/locations/{location}/certificateIssuanceConfigs/{certificate_issuance_config}', + 'certificateMap' => 'projects/{project}/locations/{location}/certificateMaps/{certificate_map}', + 'certificateMapEntry' => 'projects/{project}/locations/{location}/certificateMaps/{certificate_map}/certificateMapEntries/{certificate_map_entry}', + 'dnsAuthorization' => 'projects/{project}/locations/{location}/dnsAuthorizations/{dns_authorization}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/CertificateManager/v1/tests/Unit/V1/Client/CertificateManagerClientTest.php b/CertificateManager/tests/Unit/V1/Client/CertificateManagerClientTest.php similarity index 100% rename from owl-bot-staging/CertificateManager/v1/tests/Unit/V1/Client/CertificateManagerClientTest.php rename to CertificateManager/tests/Unit/V1/Client/CertificateManagerClientTest.php diff --git a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/create_challenge.php b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/create_challenge.php index cd694003c191..26af3b9671ba 100644 --- a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/create_challenge.php +++ b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/create_challenge.php @@ -25,7 +25,8 @@ // [START confidentialcomputing_v1_generated_ConfidentialComputing_CreateChallenge_sync] use Google\ApiCore\ApiException; use Google\Cloud\ConfidentialComputing\V1\Challenge; -use Google\Cloud\ConfidentialComputing\V1\ConfidentialComputingClient; +use Google\Cloud\ConfidentialComputing\V1\Client\ConfidentialComputingClient; +use Google\Cloud\ConfidentialComputing\V1\CreateChallengeRequest; /** * Creates a new Challenge in a given project and location. @@ -39,13 +40,16 @@ function create_challenge_sample(string $formattedParent): void // Create a client. $confidentialComputingClient = new ConfidentialComputingClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $challenge = new Challenge(); + $request = (new CreateChallengeRequest()) + ->setParent($formattedParent) + ->setChallenge($challenge); // Call the API and handle any network failures. try { /** @var Challenge $response */ - $response = $confidentialComputingClient->createChallenge($formattedParent, $challenge); + $response = $confidentialComputingClient->createChallenge($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/get_location.php b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/get_location.php index eac0ccdf2a1f..9e8b93c11b06 100644 --- a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/get_location.php +++ b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/get_location.php @@ -24,7 +24,8 @@ // [START confidentialcomputing_v1_generated_ConfidentialComputing_GetLocation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ConfidentialComputing\V1\ConfidentialComputingClient; +use Google\Cloud\ConfidentialComputing\V1\Client\ConfidentialComputingClient; +use Google\Cloud\Location\GetLocationRequest; use Google\Cloud\Location\Location; /** @@ -41,10 +42,13 @@ function get_location_sample(): void // Create a client. $confidentialComputingClient = new ConfidentialComputingClient(); + // Prepare the request message. + $request = new GetLocationRequest(); + // Call the API and handle any network failures. try { /** @var Location $response */ - $response = $confidentialComputingClient->getLocation(); + $response = $confidentialComputingClient->getLocation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/list_locations.php b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/list_locations.php index 768c9dc8a49c..cdbfe21c4cf4 100644 --- a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/list_locations.php +++ b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/list_locations.php @@ -25,7 +25,8 @@ // [START confidentialcomputing_v1_generated_ConfidentialComputing_ListLocations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\ConfidentialComputing\V1\ConfidentialComputingClient; +use Google\Cloud\ConfidentialComputing\V1\Client\ConfidentialComputingClient; +use Google\Cloud\Location\ListLocationsRequest; use Google\Cloud\Location\Location; /** @@ -42,10 +43,13 @@ function list_locations_sample(): void // Create a client. $confidentialComputingClient = new ConfidentialComputingClient(); + // Prepare the request message. + $request = new ListLocationsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $confidentialComputingClient->listLocations(); + $response = $confidentialComputingClient->listLocations($request); /** @var Location $element */ foreach ($response as $element) { diff --git a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/verify_attestation.php b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/verify_attestation.php index 43e4a80637c6..87b339f829db 100644 --- a/ConfidentialComputing/samples/V1/ConfidentialComputingClient/verify_attestation.php +++ b/ConfidentialComputing/samples/V1/ConfidentialComputingClient/verify_attestation.php @@ -24,8 +24,9 @@ // [START confidentialcomputing_v1_generated_ConfidentialComputing_VerifyAttestation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\ConfidentialComputing\V1\ConfidentialComputingClient; +use Google\Cloud\ConfidentialComputing\V1\Client\ConfidentialComputingClient; use Google\Cloud\ConfidentialComputing\V1\TpmAttestation; +use Google\Cloud\ConfidentialComputing\V1\VerifyAttestationRequest; use Google\Cloud\ConfidentialComputing\V1\VerifyAttestationResponse; /** @@ -41,13 +42,16 @@ function verify_attestation_sample(string $formattedChallenge): void // Create a client. $confidentialComputingClient = new ConfidentialComputingClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $tpmAttestation = new TpmAttestation(); + $request = (new VerifyAttestationRequest()) + ->setChallenge($formattedChallenge) + ->setTpmAttestation($tpmAttestation); // Call the API and handle any network failures. try { /** @var VerifyAttestationResponse $response */ - $response = $confidentialComputingClient->verifyAttestation($formattedChallenge, $tpmAttestation); + $response = $confidentialComputingClient->verifyAttestation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/Client/BaseClient/ConfidentialComputingBaseClient.php b/ConfidentialComputing/src/V1/Client/BaseClient/ConfidentialComputingBaseClient.php similarity index 100% rename from owl-bot-staging/ConfidentialComputing/v1/src/V1/Client/BaseClient/ConfidentialComputingBaseClient.php rename to ConfidentialComputing/src/V1/Client/BaseClient/ConfidentialComputingBaseClient.php diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/Client/ConfidentialComputingClient.php b/ConfidentialComputing/src/V1/Client/ConfidentialComputingClient.php similarity index 100% rename from owl-bot-staging/ConfidentialComputing/v1/src/V1/Client/ConfidentialComputingClient.php rename to ConfidentialComputing/src/V1/Client/ConfidentialComputingClient.php diff --git a/ConfidentialComputing/src/V1/CreateChallengeRequest.php b/ConfidentialComputing/src/V1/CreateChallengeRequest.php index d8bbd64905f4..384853512d20 100644 --- a/ConfidentialComputing/src/V1/CreateChallengeRequest.php +++ b/ConfidentialComputing/src/V1/CreateChallengeRequest.php @@ -30,6 +30,24 @@ class CreateChallengeRequest extends \Google\Protobuf\Internal\Message */ protected $challenge = null; + /** + * @param string $parent Required. The resource name of the location where the Challenge will be + * used, in the format `projects/*/locations/*`. Please see + * {@see ConfidentialComputingClient::locationName()} for help formatting this field. + * @param \Google\Cloud\ConfidentialComputing\V1\Challenge $challenge Required. The Challenge to be created. Currently this field can be empty as + * all the Challenge fields are set by the server. + * + * @return \Google\Cloud\ConfidentialComputing\V1\CreateChallengeRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\ConfidentialComputing\V1\Challenge $challenge): self + { + return (new self()) + ->setParent($parent) + ->setChallenge($challenge); + } + /** * Constructor. * diff --git a/ConfidentialComputing/src/V1/resources/confidential_computing_descriptor_config.php b/ConfidentialComputing/src/V1/resources/confidential_computing_descriptor_config.php index 0b57f8eee133..8ab43815b29c 100644 --- a/ConfidentialComputing/src/V1/resources/confidential_computing_descriptor_config.php +++ b/ConfidentialComputing/src/V1/resources/confidential_computing_descriptor_config.php @@ -3,7 +3,41 @@ return [ 'interfaces' => [ 'google.cloud.confidentialcomputing.v1.ConfidentialComputing' => [ + 'CreateChallenge' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ConfidentialComputing\V1\Challenge', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'VerifyAttestation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ConfidentialComputing\V1\VerifyAttestationResponse', + 'headerParams' => [ + [ + 'keyName' => 'challenge', + 'fieldAccessors' => [ + 'getChallenge', + ], + ], + ], + ], 'GetLocation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Location\Location', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], 'ListLocations' => [ @@ -15,8 +49,22 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLocations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], 'interfaceOverride' => 'google.cloud.location.Locations', ], + 'templateMap' => [ + 'challenge' => 'projects/{project}/locations/{location}/challenges/{uuid}', + 'location' => 'projects/{project}/locations/{location}', + ], ], ], ]; diff --git a/owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/Client/ConfidentialComputingClientTest.php b/ConfidentialComputing/tests/Unit/V1/Client/ConfidentialComputingClientTest.php similarity index 100% rename from owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/Client/ConfidentialComputingClientTest.php rename to ConfidentialComputing/tests/Unit/V1/Client/ConfidentialComputingClientTest.php diff --git a/DataCatalogLineage/samples/V1/LineageClient/batch_search_link_processes.php b/DataCatalogLineage/samples/V1/LineageClient/batch_search_link_processes.php index 5952d9f44088..fc1b44d52cd3 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/batch_search_link_processes.php +++ b/DataCatalogLineage/samples/V1/LineageClient/batch_search_link_processes.php @@ -25,7 +25,8 @@ // [START datalineage_v1_generated_Lineage_BatchSearchLinkProcesses_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesRequest; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; use Google\Cloud\DataCatalog\Lineage\V1\ProcessLinks; /** @@ -59,13 +60,16 @@ function batch_search_link_processes_sample(string $formattedParent, string $lin // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $links = [$linksElement,]; + $request = (new BatchSearchLinkProcessesRequest()) + ->setParent($formattedParent) + ->setLinks($links); // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $lineageClient->batchSearchLinkProcesses($formattedParent, $links); + $response = $lineageClient->batchSearchLinkProcesses($request); /** @var ProcessLinks $element */ foreach ($response as $element) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/create_lineage_event.php b/DataCatalogLineage/samples/V1/LineageClient/create_lineage_event.php index bf47bff0e5a3..708598c1828e 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/create_lineage_event.php +++ b/DataCatalogLineage/samples/V1/LineageClient/create_lineage_event.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_CreateLineageEvent_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\CreateLineageEventRequest; use Google\Cloud\DataCatalog\Lineage\V1\LineageEvent; /** @@ -38,13 +39,16 @@ function create_lineage_event_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $lineageEvent = new LineageEvent(); + $request = (new CreateLineageEventRequest()) + ->setParent($formattedParent) + ->setLineageEvent($lineageEvent); // Call the API and handle any network failures. try { /** @var LineageEvent $response */ - $response = $lineageClient->createLineageEvent($formattedParent, $lineageEvent); + $response = $lineageClient->createLineageEvent($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/create_process.php b/DataCatalogLineage/samples/V1/LineageClient/create_process.php index 9ba016ce1887..de3bd8e24140 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/create_process.php +++ b/DataCatalogLineage/samples/V1/LineageClient/create_process.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_CreateProcess_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\CreateProcessRequest; use Google\Cloud\DataCatalog\Lineage\V1\Process; /** @@ -39,13 +40,16 @@ function create_process_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $process = new Process(); + $request = (new CreateProcessRequest()) + ->setParent($formattedParent) + ->setProcess($process); // Call the API and handle any network failures. try { /** @var Process $response */ - $response = $lineageClient->createProcess($formattedParent, $process); + $response = $lineageClient->createProcess($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/create_run.php b/DataCatalogLineage/samples/V1/LineageClient/create_run.php index a2acbc02350a..0a001b418cd4 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/create_run.php +++ b/DataCatalogLineage/samples/V1/LineageClient/create_run.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_CreateRun_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\CreateRunRequest; use Google\Cloud\DataCatalog\Lineage\V1\Run; use Google\Cloud\DataCatalog\Lineage\V1\Run\State; use Google\Protobuf\Timestamp; @@ -41,16 +42,19 @@ function create_run_sample(string $formattedParent, int $runState): void // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $runStartTime = new Timestamp(); $run = (new Run()) ->setStartTime($runStartTime) ->setState($runState); + $request = (new CreateRunRequest()) + ->setParent($formattedParent) + ->setRun($run); // Call the API and handle any network failures. try { /** @var Run $response */ - $response = $lineageClient->createRun($formattedParent, $run); + $response = $lineageClient->createRun($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/delete_lineage_event.php b/DataCatalogLineage/samples/V1/LineageClient/delete_lineage_event.php index 70a2d2ae930a..a44e3cbec51a 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/delete_lineage_event.php +++ b/DataCatalogLineage/samples/V1/LineageClient/delete_lineage_event.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_DeleteLineageEvent_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\DeleteLineageEventRequest; /** * Deletes the lineage event with the specified name. @@ -37,9 +38,13 @@ function delete_lineage_event_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new DeleteLineageEventRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $lineageClient->deleteLineageEvent($formattedName); + $lineageClient->deleteLineageEvent($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/delete_process.php b/DataCatalogLineage/samples/V1/LineageClient/delete_process.php index ceb1afa2165a..9e847a3a522f 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/delete_process.php +++ b/DataCatalogLineage/samples/V1/LineageClient/delete_process.php @@ -25,7 +25,8 @@ // [START datalineage_v1_generated_Lineage_DeleteProcess_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\DeleteProcessRequest; use Google\Rpc\Status; /** @@ -39,10 +40,14 @@ function delete_process_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new DeleteProcessRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $lineageClient->deleteProcess($formattedName); + $response = $lineageClient->deleteProcess($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/delete_run.php b/DataCatalogLineage/samples/V1/LineageClient/delete_run.php index a23d67e4066d..d54daa9b613f 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/delete_run.php +++ b/DataCatalogLineage/samples/V1/LineageClient/delete_run.php @@ -25,7 +25,8 @@ // [START datalineage_v1_generated_Lineage_DeleteRun_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\DeleteRunRequest; use Google\Rpc\Status; /** @@ -39,10 +40,14 @@ function delete_run_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new DeleteRunRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $lineageClient->deleteRun($formattedName); + $response = $lineageClient->deleteRun($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/get_lineage_event.php b/DataCatalogLineage/samples/V1/LineageClient/get_lineage_event.php index 81bcb9ba8366..af73bcd87409 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/get_lineage_event.php +++ b/DataCatalogLineage/samples/V1/LineageClient/get_lineage_event.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_GetLineageEvent_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\GetLineageEventRequest; use Google\Cloud\DataCatalog\Lineage\V1\LineageEvent; /** @@ -38,10 +39,14 @@ function get_lineage_event_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new GetLineageEventRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var LineageEvent $response */ - $response = $lineageClient->getLineageEvent($formattedName); + $response = $lineageClient->getLineageEvent($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/get_process.php b/DataCatalogLineage/samples/V1/LineageClient/get_process.php index fce2c4fa0b44..bbcb7725fbd8 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/get_process.php +++ b/DataCatalogLineage/samples/V1/LineageClient/get_process.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_GetProcess_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\GetProcessRequest; use Google\Cloud\DataCatalog\Lineage\V1\Process; /** @@ -38,10 +39,14 @@ function get_process_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new GetProcessRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Process $response */ - $response = $lineageClient->getProcess($formattedName); + $response = $lineageClient->getProcess($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/get_run.php b/DataCatalogLineage/samples/V1/LineageClient/get_run.php index e788648268d6..1c7f828f3747 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/get_run.php +++ b/DataCatalogLineage/samples/V1/LineageClient/get_run.php @@ -24,7 +24,8 @@ // [START datalineage_v1_generated_Lineage_GetRun_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\GetRunRequest; use Google\Cloud\DataCatalog\Lineage\V1\Run; /** @@ -38,10 +39,14 @@ function get_run_sample(string $formattedName): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new GetRunRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Run $response */ - $response = $lineageClient->getRun($formattedName); + $response = $lineageClient->getRun($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/list_lineage_events.php b/DataCatalogLineage/samples/V1/LineageClient/list_lineage_events.php index 0f275078c237..6d9d7d95410f 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/list_lineage_events.php +++ b/DataCatalogLineage/samples/V1/LineageClient/list_lineage_events.php @@ -25,8 +25,9 @@ // [START datalineage_v1_generated_Lineage_ListLineageEvents_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; use Google\Cloud\DataCatalog\Lineage\V1\LineageEvent; +use Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsRequest; /** * Lists lineage events in the given project and location. The list order is @@ -40,10 +41,14 @@ function list_lineage_events_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new ListLineageEventsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $lineageClient->listLineageEvents($formattedParent); + $response = $lineageClient->listLineageEvents($request); /** @var LineageEvent $element */ foreach ($response as $element) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/list_processes.php b/DataCatalogLineage/samples/V1/LineageClient/list_processes.php index d36237304af8..cc374dcf0524 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/list_processes.php +++ b/DataCatalogLineage/samples/V1/LineageClient/list_processes.php @@ -25,7 +25,8 @@ // [START datalineage_v1_generated_Lineage_ListProcesses_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\ListProcessesRequest; use Google\Cloud\DataCatalog\Lineage\V1\Process; /** @@ -41,10 +42,14 @@ function list_processes_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new ListProcessesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $lineageClient->listProcesses($formattedParent); + $response = $lineageClient->listProcesses($request); /** @var Process $element */ foreach ($response as $element) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/list_runs.php b/DataCatalogLineage/samples/V1/LineageClient/list_runs.php index f8eae4ee2f01..966835a13579 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/list_runs.php +++ b/DataCatalogLineage/samples/V1/LineageClient/list_runs.php @@ -25,7 +25,8 @@ // [START datalineage_v1_generated_Lineage_ListRuns_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\ListRunsRequest; use Google\Cloud\DataCatalog\Lineage\V1\Run; /** @@ -40,10 +41,14 @@ function list_runs_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new ListRunsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $lineageClient->listRuns($formattedParent); + $response = $lineageClient->listRuns($request); /** @var Run $element */ foreach ($response as $element) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/search_links.php b/DataCatalogLineage/samples/V1/LineageClient/search_links.php index 55c85b5d62ad..84d588e16a42 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/search_links.php +++ b/DataCatalogLineage/samples/V1/LineageClient/search_links.php @@ -25,8 +25,9 @@ // [START datalineage_v1_generated_Lineage_SearchLinks_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; use Google\Cloud\DataCatalog\Lineage\V1\Link; +use Google\Cloud\DataCatalog\Lineage\V1\SearchLinksRequest; /** * Retrieve a list of links connected to a specific asset. @@ -47,10 +48,14 @@ function search_links_sample(string $formattedParent): void // Create a client. $lineageClient = new LineageClient(); + // Prepare the request message. + $request = (new SearchLinksRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $lineageClient->searchLinks($formattedParent); + $response = $lineageClient->searchLinks($request); /** @var Link $element */ foreach ($response as $element) { diff --git a/DataCatalogLineage/samples/V1/LineageClient/update_process.php b/DataCatalogLineage/samples/V1/LineageClient/update_process.php index 4a7fba9bb347..706330545719 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/update_process.php +++ b/DataCatalogLineage/samples/V1/LineageClient/update_process.php @@ -24,8 +24,9 @@ // [START datalineage_v1_generated_Lineage_UpdateProcess_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; use Google\Cloud\DataCatalog\Lineage\V1\Process; +use Google\Cloud\DataCatalog\Lineage\V1\UpdateProcessRequest; /** * Updates a process. @@ -41,13 +42,15 @@ function update_process_sample(): void // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $process = new Process(); + $request = (new UpdateProcessRequest()) + ->setProcess($process); // Call the API and handle any network failures. try { /** @var Process $response */ - $response = $lineageClient->updateProcess($process); + $response = $lineageClient->updateProcess($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataCatalogLineage/samples/V1/LineageClient/update_run.php b/DataCatalogLineage/samples/V1/LineageClient/update_run.php index fe1047b63ef1..c8acb38a692d 100644 --- a/DataCatalogLineage/samples/V1/LineageClient/update_run.php +++ b/DataCatalogLineage/samples/V1/LineageClient/update_run.php @@ -24,9 +24,10 @@ // [START datalineage_v1_generated_Lineage_UpdateRun_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataCatalog\Lineage\V1\LineageClient; +use Google\Cloud\DataCatalog\Lineage\V1\Client\LineageClient; use Google\Cloud\DataCatalog\Lineage\V1\Run; use Google\Cloud\DataCatalog\Lineage\V1\Run\State; +use Google\Cloud\DataCatalog\Lineage\V1\UpdateRunRequest; use Google\Protobuf\Timestamp; /** @@ -39,16 +40,18 @@ function update_run_sample(int $runState): void // Create a client. $lineageClient = new LineageClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $runStartTime = new Timestamp(); $run = (new Run()) ->setStartTime($runStartTime) ->setState($runState); + $request = (new UpdateRunRequest()) + ->setRun($run); // Call the API and handle any network failures. try { /** @var Run $response */ - $response = $lineageClient->updateRun($run); + $response = $lineageClient->updateRun($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/DataCatalogLineage/v1/src/V1/Client/BaseClient/LineageBaseClient.php b/DataCatalogLineage/src/V1/Client/BaseClient/LineageBaseClient.php similarity index 100% rename from owl-bot-staging/DataCatalogLineage/v1/src/V1/Client/BaseClient/LineageBaseClient.php rename to DataCatalogLineage/src/V1/Client/BaseClient/LineageBaseClient.php diff --git a/owl-bot-staging/DataCatalogLineage/v1/src/V1/Client/LineageClient.php b/DataCatalogLineage/src/V1/Client/LineageClient.php similarity index 100% rename from owl-bot-staging/DataCatalogLineage/v1/src/V1/Client/LineageClient.php rename to DataCatalogLineage/src/V1/Client/LineageClient.php diff --git a/DataCatalogLineage/src/V1/CreateLineageEventRequest.php b/DataCatalogLineage/src/V1/CreateLineageEventRequest.php index 668fd4f8f23c..dbe80ec46995 100644 --- a/DataCatalogLineage/src/V1/CreateLineageEventRequest.php +++ b/DataCatalogLineage/src/V1/CreateLineageEventRequest.php @@ -37,6 +37,22 @@ class CreateLineageEventRequest extends \Google\Protobuf\Internal\Message */ protected $request_id = ''; + /** + * @param string $parent Required. The name of the run that should own the lineage event. Please see + * {@see LineageClient::runName()} for help formatting this field. + * @param \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $lineageEvent Required. The lineage event to create. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateLineageEventRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $lineageEvent): self + { + return (new self()) + ->setParent($parent) + ->setLineageEvent($lineageEvent); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/CreateProcessRequest.php b/DataCatalogLineage/src/V1/CreateProcessRequest.php index 5f978b6127c1..aa9d1ebaaee6 100644 --- a/DataCatalogLineage/src/V1/CreateProcessRequest.php +++ b/DataCatalogLineage/src/V1/CreateProcessRequest.php @@ -38,6 +38,23 @@ class CreateProcessRequest extends \Google\Protobuf\Internal\Message */ protected $request_id = ''; + /** + * @param string $parent Required. The name of the project and its location that should own the + * process. Please see + * {@see LineageClient::locationName()} for help formatting this field. + * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $process Required. The process to create. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateProcessRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\Process $process): self + { + return (new self()) + ->setParent($parent) + ->setProcess($process); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/CreateRunRequest.php b/DataCatalogLineage/src/V1/CreateRunRequest.php index aa2cd4b3cc83..67ac72ae8277 100644 --- a/DataCatalogLineage/src/V1/CreateRunRequest.php +++ b/DataCatalogLineage/src/V1/CreateRunRequest.php @@ -37,6 +37,22 @@ class CreateRunRequest extends \Google\Protobuf\Internal\Message */ protected $request_id = ''; + /** + * @param string $parent Required. The name of the process that should own the run. Please see + * {@see LineageClient::processName()} for help formatting this field. + * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $run Required. The run to create. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateRunRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\Run $run): self + { + return (new self()) + ->setParent($parent) + ->setRun($run); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/DeleteLineageEventRequest.php b/DataCatalogLineage/src/V1/DeleteLineageEventRequest.php index f2ccd7dd1fe9..18b9d21a24a2 100644 --- a/DataCatalogLineage/src/V1/DeleteLineageEventRequest.php +++ b/DataCatalogLineage/src/V1/DeleteLineageEventRequest.php @@ -30,6 +30,20 @@ class DeleteLineageEventRequest extends \Google\Protobuf\Internal\Message */ protected $allow_missing = false; + /** + * @param string $name Required. The name of the lineage event to delete. Please see + * {@see LineageClient::lineageEventName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteLineageEventRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/DeleteProcessRequest.php b/DataCatalogLineage/src/V1/DeleteProcessRequest.php index 3def3790f9f9..088e68cffa5b 100644 --- a/DataCatalogLineage/src/V1/DeleteProcessRequest.php +++ b/DataCatalogLineage/src/V1/DeleteProcessRequest.php @@ -30,6 +30,20 @@ class DeleteProcessRequest extends \Google\Protobuf\Internal\Message */ protected $allow_missing = false; + /** + * @param string $name Required. The name of the process to delete. Please see + * {@see LineageClient::processName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteProcessRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/DeleteRunRequest.php b/DataCatalogLineage/src/V1/DeleteRunRequest.php index ce082b1b958f..bcc506513f22 100644 --- a/DataCatalogLineage/src/V1/DeleteRunRequest.php +++ b/DataCatalogLineage/src/V1/DeleteRunRequest.php @@ -30,6 +30,20 @@ class DeleteRunRequest extends \Google\Protobuf\Internal\Message */ protected $allow_missing = false; + /** + * @param string $name Required. The name of the run to delete. Please see + * {@see LineageClient::runName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteRunRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/GetLineageEventRequest.php b/DataCatalogLineage/src/V1/GetLineageEventRequest.php index 0c072d97fd85..bcfbb6140411 100644 --- a/DataCatalogLineage/src/V1/GetLineageEventRequest.php +++ b/DataCatalogLineage/src/V1/GetLineageEventRequest.php @@ -23,6 +23,20 @@ class GetLineageEventRequest extends \Google\Protobuf\Internal\Message */ protected $name = ''; + /** + * @param string $name Required. The name of the lineage event to get. Please see + * {@see LineageClient::lineageEventName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\GetLineageEventRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/GetProcessRequest.php b/DataCatalogLineage/src/V1/GetProcessRequest.php index 5d38c9a90916..7f23ce58f182 100644 --- a/DataCatalogLineage/src/V1/GetProcessRequest.php +++ b/DataCatalogLineage/src/V1/GetProcessRequest.php @@ -23,6 +23,20 @@ class GetProcessRequest extends \Google\Protobuf\Internal\Message */ protected $name = ''; + /** + * @param string $name Required. The name of the process to get. Please see + * {@see LineageClient::processName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\GetProcessRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/GetRunRequest.php b/DataCatalogLineage/src/V1/GetRunRequest.php index bb663ee0bb71..b0f0b84a2848 100644 --- a/DataCatalogLineage/src/V1/GetRunRequest.php +++ b/DataCatalogLineage/src/V1/GetRunRequest.php @@ -23,6 +23,20 @@ class GetRunRequest extends \Google\Protobuf\Internal\Message */ protected $name = ''; + /** + * @param string $name Required. The name of the run to get. Please see + * {@see LineageClient::runName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\GetRunRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/ListLineageEventsRequest.php b/DataCatalogLineage/src/V1/ListLineageEventsRequest.php index 694c5bc8a303..02a1847041af 100644 --- a/DataCatalogLineage/src/V1/ListLineageEventsRequest.php +++ b/DataCatalogLineage/src/V1/ListLineageEventsRequest.php @@ -42,6 +42,20 @@ class ListLineageEventsRequest extends \Google\Protobuf\Internal\Message */ protected $page_token = ''; + /** + * @param string $parent Required. The name of the run that owns the collection of lineage events to + * get. Please see {@see LineageClient::runName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/ListProcessesRequest.php b/DataCatalogLineage/src/V1/ListProcessesRequest.php index 67c88e21b6f6..1b81bb00d128 100644 --- a/DataCatalogLineage/src/V1/ListProcessesRequest.php +++ b/DataCatalogLineage/src/V1/ListProcessesRequest.php @@ -42,6 +42,21 @@ class ListProcessesRequest extends \Google\Protobuf\Internal\Message */ protected $page_token = ''; + /** + * @param string $parent Required. The name of the project and its location that owns this + * collection of processes. Please see + * {@see LineageClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\ListProcessesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/ListRunsRequest.php b/DataCatalogLineage/src/V1/ListRunsRequest.php index ec4af6ff6da4..6a762c1e9dcd 100644 --- a/DataCatalogLineage/src/V1/ListRunsRequest.php +++ b/DataCatalogLineage/src/V1/ListRunsRequest.php @@ -41,6 +41,20 @@ class ListRunsRequest extends \Google\Protobuf\Internal\Message */ protected $page_token = ''; + /** + * @param string $parent Required. The name of process that owns this collection of runs. Please see + * {@see LineageClient::processName()} for help formatting this field. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\ListRunsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/UpdateProcessRequest.php b/DataCatalogLineage/src/V1/UpdateProcessRequest.php index 15179d4514d5..9b26ec7372de 100644 --- a/DataCatalogLineage/src/V1/UpdateProcessRequest.php +++ b/DataCatalogLineage/src/V1/UpdateProcessRequest.php @@ -37,6 +37,24 @@ class UpdateProcessRequest extends \Google\Protobuf\Internal\Message */ protected $allow_missing = false; + /** + * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $process Required. The lineage process to update. + * + * The process's `name` field is used to identify the process to update. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. Currently not used. The whole message is + * updated. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\UpdateProcessRequest + * + * @experimental + */ + public static function build(\Google\Cloud\DataCatalog\Lineage\V1\Process $process, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setProcess($process) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/UpdateRunRequest.php b/DataCatalogLineage/src/V1/UpdateRunRequest.php index cbe3dfc45b99..72b5866ce820 100644 --- a/DataCatalogLineage/src/V1/UpdateRunRequest.php +++ b/DataCatalogLineage/src/V1/UpdateRunRequest.php @@ -33,6 +33,27 @@ class UpdateRunRequest extends \Google\Protobuf\Internal\Message */ protected $update_mask = null; + /** + * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $run Required. The lineage run to update. + * + * The run's `name` field is used to identify the run to update. + * + * Format: + * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. Currently not used. The whole message is + * updated. + * + * @return \Google\Cloud\DataCatalog\Lineage\V1\UpdateRunRequest + * + * @experimental + */ + public static function build(\Google\Cloud\DataCatalog\Lineage\V1\Run $run, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setRun($run) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/DataCatalogLineage/src/V1/resources/lineage_descriptor_config.php b/DataCatalogLineage/src/V1/resources/lineage_descriptor_config.php index 200a251ac0ab..6ead216d0eb0 100644 --- a/DataCatalogLineage/src/V1/resources/lineage_descriptor_config.php +++ b/DataCatalogLineage/src/V1/resources/lineage_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'DeleteRun' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'BatchSearchLinkProcesses' => [ 'pageStreaming' => [ @@ -32,6 +50,100 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getProcessLinks', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateLineageEvent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateProcess' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateRun' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteLineageEvent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetLineageEvent' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetProcess' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetRun' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListLineageEvents' => [ 'pageStreaming' => [ @@ -42,6 +154,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLineageEvents', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListProcesses' => [ 'pageStreaming' => [ @@ -52,6 +174,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getProcesses', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListProcessesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListRuns' => [ 'pageStreaming' => [ @@ -62,6 +194,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getRuns', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListRunsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'SearchLinks' => [ 'pageStreaming' => [ @@ -72,6 +214,48 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getLinks', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\SearchLinksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateProcess' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', + 'headerParams' => [ + [ + 'keyName' => 'process.name', + 'fieldAccessors' => [ + 'getProcess', + 'getName', + ], + ], + ], + ], + 'UpdateRun' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', + 'headerParams' => [ + [ + 'keyName' => 'run.name', + 'fieldAccessors' => [ + 'getRun', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'lineageEvent' => 'projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}', + 'location' => 'projects/{project}/locations/{location}', + 'process' => 'projects/{project}/locations/{location}/processes/{process}', + 'run' => 'projects/{project}/locations/{location}/processes/{process}/runs/{run}', ], ], ], diff --git a/owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/Client/LineageClientTest.php b/DataCatalogLineage/tests/Unit/V1/Client/LineageClientTest.php similarity index 100% rename from owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/Client/LineageClientTest.php rename to DataCatalogLineage/tests/Unit/V1/Client/LineageClientTest.php diff --git a/DataFusion/samples/V1/DataFusionClient/create_instance.php b/DataFusion/samples/V1/DataFusionClient/create_instance.php index 5c895b889410..6cc9fad762bc 100644 --- a/DataFusion/samples/V1/DataFusionClient/create_instance.php +++ b/DataFusion/samples/V1/DataFusionClient/create_instance.php @@ -25,7 +25,8 @@ // [START datafusion_v1_generated_DataFusion_CreateInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; +use Google\Cloud\DataFusion\V1\CreateInstanceRequest; use Google\Cloud\DataFusion\V1\Instance; use Google\Rpc\Status; @@ -42,10 +43,15 @@ function create_instance_sample(string $formattedParent, string $instanceId): vo // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new CreateInstanceRequest()) + ->setParent($formattedParent) + ->setInstanceId($instanceId); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataFusionClient->createInstance($formattedParent, $instanceId); + $response = $dataFusionClient->createInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataFusion/samples/V1/DataFusionClient/delete_instance.php b/DataFusion/samples/V1/DataFusionClient/delete_instance.php index a4e7aad4d373..9b208e78c9d3 100644 --- a/DataFusion/samples/V1/DataFusionClient/delete_instance.php +++ b/DataFusion/samples/V1/DataFusionClient/delete_instance.php @@ -25,7 +25,8 @@ // [START datafusion_v1_generated_DataFusion_DeleteInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; +use Google\Cloud\DataFusion\V1\DeleteInstanceRequest; use Google\Rpc\Status; /** @@ -40,10 +41,14 @@ function delete_instance_sample(string $formattedName): void // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new DeleteInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataFusionClient->deleteInstance($formattedName); + $response = $dataFusionClient->deleteInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataFusion/samples/V1/DataFusionClient/get_instance.php b/DataFusion/samples/V1/DataFusionClient/get_instance.php index 0c9862427ba4..3bbce1a6ad61 100644 --- a/DataFusion/samples/V1/DataFusionClient/get_instance.php +++ b/DataFusion/samples/V1/DataFusionClient/get_instance.php @@ -24,7 +24,8 @@ // [START datafusion_v1_generated_DataFusion_GetInstance_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; +use Google\Cloud\DataFusion\V1\GetInstanceRequest; use Google\Cloud\DataFusion\V1\Instance; /** @@ -39,10 +40,14 @@ function get_instance_sample(string $formattedName): void // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new GetInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Instance $response */ - $response = $dataFusionClient->getInstance($formattedName); + $response = $dataFusionClient->getInstance($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataFusion/samples/V1/DataFusionClient/list_available_versions.php b/DataFusion/samples/V1/DataFusionClient/list_available_versions.php index 9bad814a6fac..8846006d3e51 100644 --- a/DataFusion/samples/V1/DataFusionClient/list_available_versions.php +++ b/DataFusion/samples/V1/DataFusionClient/list_available_versions.php @@ -25,7 +25,8 @@ // [START datafusion_v1_generated_DataFusion_ListAvailableVersions_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; +use Google\Cloud\DataFusion\V1\ListAvailableVersionsRequest; use Google\Cloud\DataFusion\V1\Version; /** @@ -41,10 +42,14 @@ function list_available_versions_sample(string $formattedParent): void // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new ListAvailableVersionsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataFusionClient->listAvailableVersions($formattedParent); + $response = $dataFusionClient->listAvailableVersions($request); /** @var Version $element */ foreach ($response as $element) { diff --git a/DataFusion/samples/V1/DataFusionClient/list_instances.php b/DataFusion/samples/V1/DataFusionClient/list_instances.php index f8ff5c64aea6..26e6eb16b8ab 100644 --- a/DataFusion/samples/V1/DataFusionClient/list_instances.php +++ b/DataFusion/samples/V1/DataFusionClient/list_instances.php @@ -25,8 +25,9 @@ // [START datafusion_v1_generated_DataFusion_ListInstances_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; use Google\Cloud\DataFusion\V1\Instance; +use Google\Cloud\DataFusion\V1\ListInstancesRequest; /** * Lists Data Fusion instances in the specified project and location. @@ -42,10 +43,14 @@ function list_instances_sample(string $formattedParent): void // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new ListInstancesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataFusionClient->listInstances($formattedParent); + $response = $dataFusionClient->listInstances($request); /** @var Instance $element */ foreach ($response as $element) { diff --git a/DataFusion/samples/V1/DataFusionClient/restart_instance.php b/DataFusion/samples/V1/DataFusionClient/restart_instance.php index 2b2da4022625..2f82512c90c7 100644 --- a/DataFusion/samples/V1/DataFusionClient/restart_instance.php +++ b/DataFusion/samples/V1/DataFusionClient/restart_instance.php @@ -25,8 +25,9 @@ // [START datafusion_v1_generated_DataFusion_RestartInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; use Google\Cloud\DataFusion\V1\Instance; +use Google\Cloud\DataFusion\V1\RestartInstanceRequest; use Google\Rpc\Status; /** @@ -42,10 +43,14 @@ function restart_instance_sample(string $formattedName): void // Create a client. $dataFusionClient = new DataFusionClient(); + // Prepare the request message. + $request = (new RestartInstanceRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataFusionClient->restartInstance($formattedName); + $response = $dataFusionClient->restartInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataFusion/samples/V1/DataFusionClient/update_instance.php b/DataFusion/samples/V1/DataFusionClient/update_instance.php index 9e87f40dd5f3..976ffa8dc74d 100644 --- a/DataFusion/samples/V1/DataFusionClient/update_instance.php +++ b/DataFusion/samples/V1/DataFusionClient/update_instance.php @@ -25,9 +25,10 @@ // [START datafusion_v1_generated_DataFusion_UpdateInstance_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataFusion\V1\DataFusionClient; +use Google\Cloud\DataFusion\V1\Client\DataFusionClient; use Google\Cloud\DataFusion\V1\Instance; use Google\Cloud\DataFusion\V1\Instance\Type; +use Google\Cloud\DataFusion\V1\UpdateInstanceRequest; use Google\Rpc\Status; /** @@ -40,14 +41,16 @@ function update_instance_sample(int $instanceType): void // Create a client. $dataFusionClient = new DataFusionClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $instance = (new Instance()) ->setType($instanceType); + $request = (new UpdateInstanceRequest()) + ->setInstance($instance); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataFusionClient->updateInstance($instance); + $response = $dataFusionClient->updateInstance($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/owl-bot-staging/DataFusion/v1/src/V1/Client/BaseClient/DataFusionBaseClient.php b/DataFusion/src/V1/Client/BaseClient/DataFusionBaseClient.php similarity index 100% rename from owl-bot-staging/DataFusion/v1/src/V1/Client/BaseClient/DataFusionBaseClient.php rename to DataFusion/src/V1/Client/BaseClient/DataFusionBaseClient.php diff --git a/owl-bot-staging/DataFusion/v1/src/V1/Client/DataFusionClient.php b/DataFusion/src/V1/Client/DataFusionClient.php similarity index 100% rename from owl-bot-staging/DataFusion/v1/src/V1/Client/DataFusionClient.php rename to DataFusion/src/V1/Client/DataFusionClient.php diff --git a/DataFusion/src/V1/CreateInstanceRequest.php b/DataFusion/src/V1/CreateInstanceRequest.php index 28d562537132..a24b04e5e3a0 100644 --- a/DataFusion/src/V1/CreateInstanceRequest.php +++ b/DataFusion/src/V1/CreateInstanceRequest.php @@ -35,6 +35,25 @@ class CreateInstanceRequest extends \Google\Protobuf\Internal\Message */ private $instance = null; + /** + * @param string $parent Required. The instance's project and location in the format + * projects/{project}/locations/{location}. Please see + * {@see DataFusionClient::locationName()} for help formatting this field. + * @param \Google\Cloud\DataFusion\V1\Instance $instance An instance resource. + * @param string $instanceId Required. The name of the instance to create. + * + * @return \Google\Cloud\DataFusion\V1\CreateInstanceRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataFusion\V1\Instance $instance, string $instanceId): self + { + return (new self()) + ->setParent($parent) + ->setInstance($instance) + ->setInstanceId($instanceId); + } + /** * Constructor. * diff --git a/DataFusion/src/V1/DeleteInstanceRequest.php b/DataFusion/src/V1/DeleteInstanceRequest.php index 12e5a6b271d6..41eb160a0659 100644 --- a/DataFusion/src/V1/DeleteInstanceRequest.php +++ b/DataFusion/src/V1/DeleteInstanceRequest.php @@ -23,6 +23,21 @@ class DeleteInstanceRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The instance resource name in the format + * projects/{project}/locations/{location}/instances/{instance} + * Please see {@see DataFusionClient::instanceName()} for help formatting this field. + * + * @return \Google\Cloud\DataFusion\V1\DeleteInstanceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataFusion/src/V1/ListAvailableVersionsRequest.php b/DataFusion/src/V1/ListAvailableVersionsRequest.php index 3412f677fc53..1d58816f2f8e 100644 --- a/DataFusion/src/V1/ListAvailableVersionsRequest.php +++ b/DataFusion/src/V1/ListAvailableVersionsRequest.php @@ -44,6 +44,21 @@ class ListAvailableVersionsRequest extends \Google\Protobuf\Internal\Message */ private $latest_patch_only = false; + /** + * @param string $parent Required. The project and location for which to retrieve instance information + * in the format projects/{project}/locations/{location}. Please see + * {@see DataFusionClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\DataFusion\V1\ListAvailableVersionsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/DataFusion/src/V1/UpdateInstanceRequest.php b/DataFusion/src/V1/UpdateInstanceRequest.php index 15ec9428ba13..2962cebafac8 100644 --- a/DataFusion/src/V1/UpdateInstanceRequest.php +++ b/DataFusion/src/V1/UpdateInstanceRequest.php @@ -37,6 +37,28 @@ class UpdateInstanceRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\DataFusion\V1\Instance $instance Required. The instance resource that replaces the resource on the server. Currently, + * Data Fusion only allows replacing labels, options, and stack driver + * settings. All other fields will be ignored. + * @param \Google\Protobuf\FieldMask $updateMask Field mask is used to specify the fields that the update will overwrite + * in an instance resource. The fields specified in the update_mask are + * relative to the resource, not the full request. + * A field will be overwritten if it is in the mask. + * If the user does not provide a mask, all the supported fields (labels, + * options, and version currently) will be overwritten. + * + * @return \Google\Cloud\DataFusion\V1\UpdateInstanceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\DataFusion\V1\Instance $instance, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setInstance($instance) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/DataFusion/src/V1/resources/data_fusion_descriptor_config.php b/DataFusion/src/V1/resources/data_fusion_descriptor_config.php index 1243e9fd3f4f..34fbd52f9e1d 100644 --- a/DataFusion/src/V1/resources/data_fusion_descriptor_config.php +++ b/DataFusion/src/V1/resources/data_fusion_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'DeleteInstance' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'RestartInstance' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'UpdateInstance' => [ 'longRunning' => [ @@ -42,6 +69,28 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'instance.name', + 'fieldAccessors' => [ + 'getInstance', + 'getName', + ], + ], + ], + ], + 'GetInstance' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataFusion\V1\Instance', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListAvailableVersions' => [ 'pageStreaming' => [ @@ -52,6 +101,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAvailableVersions', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataFusion\V1\ListAvailableVersionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListInstances' => [ 'pageStreaming' => [ @@ -62,6 +121,21 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getInstances', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataFusion\V1\ListInstancesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'templateMap' => [ + 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', + 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', + 'location' => 'projects/{project}/locations/{location}', ], ], ], diff --git a/owl-bot-staging/DataFusion/v1/tests/Unit/V1/Client/DataFusionClientTest.php b/DataFusion/tests/Unit/V1/Client/DataFusionClientTest.php similarity index 100% rename from owl-bot-staging/DataFusion/v1/tests/Unit/V1/Client/DataFusionClientTest.php rename to DataFusion/tests/Unit/V1/Client/DataFusionClientTest.php diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_annotation_spec_set.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_annotation_spec_set.php index af3db47e9c37..25694461f1cf 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_annotation_spec_set.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_annotation_spec_set.php @@ -25,7 +25,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_CreateAnnotationSpecSet_sync] use Google\ApiCore\ApiException; use Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\CreateAnnotationSpecSetRequest; /** * Creates an annotation spec set by providing a set of labels. @@ -39,16 +40,16 @@ function create_annotation_spec_set_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $annotationSpecSet = new AnnotationSpecSet(); + $request = (new CreateAnnotationSpecSetRequest()) + ->setParent($formattedParent) + ->setAnnotationSpecSet($annotationSpecSet); // Call the API and handle any network failures. try { /** @var AnnotationSpecSet $response */ - $response = $dataLabelingServiceClient->createAnnotationSpecSet( - $formattedParent, - $annotationSpecSet - ); + $response = $dataLabelingServiceClient->createAnnotationSpecSet($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_dataset.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_dataset.php index 1f933747a2df..72d7632f70ec 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_dataset.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_dataset.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_CreateDataset_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\CreateDatasetRequest; use Google\Cloud\DataLabeling\V1beta1\Dataset; /** @@ -39,13 +40,16 @@ function create_dataset_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $dataset = new Dataset(); + $request = (new CreateDatasetRequest()) + ->setParent($formattedParent) + ->setDataset($dataset); // Call the API and handle any network failures. try { /** @var Dataset $response */ - $response = $dataLabelingServiceClient->createDataset($formattedParent, $dataset); + $response = $dataLabelingServiceClient->createDataset($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_evaluation_job.php index e4bd52295345..07c97cdf4174 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_evaluation_job.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_CreateEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\CreateEvaluationJobRequest; use Google\Cloud\DataLabeling\V1beta1\EvaluationJob; /** @@ -39,13 +40,16 @@ function create_evaluation_job_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $job = new EvaluationJob(); + $request = (new CreateEvaluationJobRequest()) + ->setParent($formattedParent) + ->setJob($job); // Call the API and handle any network failures. try { /** @var EvaluationJob $response */ - $response = $dataLabelingServiceClient->createEvaluationJob($formattedParent, $job); + $response = $dataLabelingServiceClient->createEvaluationJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_instruction.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_instruction.php index 4426e3b0a548..c2e0b473cda0 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_instruction.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/create_instruction.php @@ -25,7 +25,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_CreateInstruction_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\CreateInstructionRequest; use Google\Cloud\DataLabeling\V1beta1\Instruction; use Google\Rpc\Status; @@ -41,13 +42,16 @@ function create_instruction_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $instruction = new Instruction(); + $request = (new CreateInstructionRequest()) + ->setParent($formattedParent) + ->setInstruction($instruction); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->createInstruction($formattedParent, $instruction); + $response = $dataLabelingServiceClient->createInstruction($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotated_dataset.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotated_dataset.php index b1e1edb02990..75368b264fc7 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotated_dataset.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotated_dataset.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_DeleteAnnotatedDataset_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\DeleteAnnotatedDatasetRequest; /** * Deletes an annotated dataset by resource name. @@ -39,9 +40,13 @@ function delete_annotated_dataset_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new DeleteAnnotatedDatasetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->deleteAnnotatedDataset($formattedName); + $dataLabelingServiceClient->deleteAnnotatedDataset($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotation_spec_set.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotation_spec_set.php index 04c50e232245..806a3fe59b39 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotation_spec_set.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_annotation_spec_set.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_DeleteAnnotationSpecSet_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\DeleteAnnotationSpecSetRequest; /** * Deletes an annotation spec set by resource name. @@ -38,9 +39,13 @@ function delete_annotation_spec_set_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new DeleteAnnotationSpecSetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->deleteAnnotationSpecSet($formattedName); + $dataLabelingServiceClient->deleteAnnotationSpecSet($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_dataset.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_dataset.php index 7132b70ddaa8..bb62cb2f0405 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_dataset.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_dataset.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_DeleteDataset_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\DeleteDatasetRequest; /** * Deletes a dataset by resource name. @@ -38,9 +39,13 @@ function delete_dataset_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new DeleteDatasetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->deleteDataset($formattedName); + $dataLabelingServiceClient->deleteDataset($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_evaluation_job.php index c537dd2345c4..d979fbf00b92 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_evaluation_job.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_DeleteEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\DeleteEvaluationJobRequest; /** * Stops and deletes an evaluation job. @@ -39,9 +40,13 @@ function delete_evaluation_job_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new DeleteEvaluationJobRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->deleteEvaluationJob($formattedName); + $dataLabelingServiceClient->deleteEvaluationJob($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_instruction.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_instruction.php index c24831ee4de9..aed96c7901a7 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_instruction.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/delete_instruction.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_DeleteInstruction_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\DeleteInstructionRequest; /** * Deletes an instruction object by resource name. @@ -38,9 +39,13 @@ function delete_instruction_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new DeleteInstructionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->deleteInstruction($formattedName); + $dataLabelingServiceClient->deleteInstruction($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/export_data.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/export_data.php index 01cf46e1f7ac..36a2d14b6420 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/export_data.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/export_data.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ExportData_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\ExportDataOperationResponse; +use Google\Cloud\DataLabeling\V1beta1\ExportDataRequest; use Google\Cloud\DataLabeling\V1beta1\OutputConfig; use Google\Rpc\Status; @@ -48,17 +49,17 @@ function export_data_sample(string $formattedName, string $formattedAnnotatedDat // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $outputConfig = new OutputConfig(); + $request = (new ExportDataRequest()) + ->setName($formattedName) + ->setAnnotatedDataset($formattedAnnotatedDataset) + ->setOutputConfig($outputConfig); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->exportData( - $formattedName, - $formattedAnnotatedDataset, - $outputConfig - ); + $response = $dataLabelingServiceClient->exportData($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotated_dataset.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotated_dataset.php index efec30d05cc7..450abfa3bca5 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotated_dataset.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotated_dataset.php @@ -25,7 +25,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetAnnotatedDataset_sync] use Google\ApiCore\ApiException; use Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\GetAnnotatedDatasetRequest; /** * Gets an annotated dataset by resource name. @@ -40,10 +41,14 @@ function get_annotated_dataset_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetAnnotatedDatasetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var AnnotatedDataset $response */ - $response = $dataLabelingServiceClient->getAnnotatedDataset($formattedName); + $response = $dataLabelingServiceClient->getAnnotatedDataset($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotation_spec_set.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotation_spec_set.php index 298fe3bc0d02..2884f35f5046 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotation_spec_set.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_annotation_spec_set.php @@ -25,7 +25,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetAnnotationSpecSet_sync] use Google\ApiCore\ApiException; use Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\GetAnnotationSpecSetRequest; /** * Gets an annotation spec set by resource name. @@ -39,10 +40,14 @@ function get_annotation_spec_set_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetAnnotationSpecSetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var AnnotationSpecSet $response */ - $response = $dataLabelingServiceClient->getAnnotationSpecSet($formattedName); + $response = $dataLabelingServiceClient->getAnnotationSpecSet($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_data_item.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_data_item.php index eb7aa137d9cb..ab04c193cf1b 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_data_item.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_data_item.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetDataItem_sync] use Google\ApiCore\ApiException; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\DataItem; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\GetDataItemRequest; /** * Gets a data item in a dataset by resource name. This API can be @@ -40,10 +41,14 @@ function get_data_item_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetDataItemRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var DataItem $response */ - $response = $dataLabelingServiceClient->getDataItem($formattedName); + $response = $dataLabelingServiceClient->getDataItem($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_dataset.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_dataset.php index 46274ae1b7c3..86c982129372 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_dataset.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_dataset.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetDataset_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Dataset; +use Google\Cloud\DataLabeling\V1beta1\GetDatasetRequest; /** * Gets dataset by resource name. @@ -39,10 +40,14 @@ function get_dataset_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetDatasetRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Dataset $response */ - $response = $dataLabelingServiceClient->getDataset($formattedName); + $response = $dataLabelingServiceClient->getDataset($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation.php index a224f5201868..52eb7b9af8d9 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetEvaluation_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Evaluation; +use Google\Cloud\DataLabeling\V1beta1\GetEvaluationRequest; /** * Gets an evaluation by resource name (to search, use @@ -41,10 +42,14 @@ function get_evaluation_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetEvaluationRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Evaluation $response */ - $response = $dataLabelingServiceClient->getEvaluation($formattedName); + $response = $dataLabelingServiceClient->getEvaluation($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation_job.php index b869b0eaa978..05a7a7c85481 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_evaluation_job.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\EvaluationJob; +use Google\Cloud\DataLabeling\V1beta1\GetEvaluationJobRequest; /** * Gets an evaluation job by resource name. @@ -40,10 +41,14 @@ function get_evaluation_job_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetEvaluationJobRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var EvaluationJob $response */ - $response = $dataLabelingServiceClient->getEvaluationJob($formattedName); + $response = $dataLabelingServiceClient->getEvaluationJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_example.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_example.php index c07ec5bfbe51..8cf3985102bf 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_example.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_example.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetExample_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Example; +use Google\Cloud\DataLabeling\V1beta1\GetExampleRequest; /** * Gets an example by resource name, including both data and annotation. @@ -40,10 +41,14 @@ function get_example_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetExampleRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Example $response */ - $response = $dataLabelingServiceClient->getExample($formattedName); + $response = $dataLabelingServiceClient->getExample($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_instruction.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_instruction.php index ae8866963bdd..1d46ce14ed3a 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_instruction.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/get_instruction.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_GetInstruction_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\GetInstructionRequest; use Google\Cloud\DataLabeling\V1beta1\Instruction; /** @@ -39,10 +40,14 @@ function get_instruction_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new GetInstructionRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { /** @var Instruction $response */ - $response = $dataLabelingServiceClient->getInstruction($formattedName); + $response = $dataLabelingServiceClient->getInstruction($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/import_data.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/import_data.php index dbac5efbd5d4..71d654495507 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/import_data.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/import_data.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ImportData_sync] use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\ImportDataOperationResponse; +use Google\Cloud\DataLabeling\V1beta1\ImportDataRequest; use Google\Cloud\DataLabeling\V1beta1\InputConfig; use Google\Rpc\Status; @@ -46,13 +47,16 @@ function import_data_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $inputConfig = new InputConfig(); + $request = (new ImportDataRequest()) + ->setName($formattedName) + ->setInputConfig($inputConfig); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->importData($formattedName, $inputConfig); + $response = $dataLabelingServiceClient->importData($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_image.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_image.php index 4e4a81b1dc61..cd4427c56edf 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_image.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_image.php @@ -26,8 +26,9 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig; +use Google\Cloud\DataLabeling\V1beta1\LabelImageRequest; use Google\Cloud\DataLabeling\V1beta1\LabelImageRequest\Feature; use Google\Rpc\Status; @@ -53,15 +54,19 @@ function label_image_sample( // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $basicConfig = (new HumanAnnotationConfig()) ->setInstruction($basicConfigInstruction) ->setAnnotatedDatasetDisplayName($basicConfigAnnotatedDatasetDisplayName); + $request = (new LabelImageRequest()) + ->setParent($formattedParent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->labelImage($formattedParent, $basicConfig, $feature); + $response = $dataLabelingServiceClient->labelImage($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_text.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_text.php index f86fe6da1ca1..d9217cfd4f37 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_text.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_text.php @@ -26,8 +26,9 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig; +use Google\Cloud\DataLabeling\V1beta1\LabelTextRequest; use Google\Cloud\DataLabeling\V1beta1\LabelTextRequest\Feature; use Google\Rpc\Status; @@ -53,15 +54,19 @@ function label_text_sample( // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $basicConfig = (new HumanAnnotationConfig()) ->setInstruction($basicConfigInstruction) ->setAnnotatedDatasetDisplayName($basicConfigAnnotatedDatasetDisplayName); + $request = (new LabelTextRequest()) + ->setParent($formattedParent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->labelText($formattedParent, $basicConfig, $feature); + $response = $dataLabelingServiceClient->labelText($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_video.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_video.php index 15f3fb6d48a1..918b1ee22c91 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_video.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/label_video.php @@ -26,8 +26,9 @@ use Google\ApiCore\ApiException; use Google\ApiCore\OperationResponse; use Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig; +use Google\Cloud\DataLabeling\V1beta1\LabelVideoRequest; use Google\Cloud\DataLabeling\V1beta1\LabelVideoRequest\Feature; use Google\Rpc\Status; @@ -53,15 +54,19 @@ function label_video_sample( // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $basicConfig = (new HumanAnnotationConfig()) ->setInstruction($basicConfigInstruction) ->setAnnotatedDatasetDisplayName($basicConfigAnnotatedDatasetDisplayName); + $request = (new LabelVideoRequest()) + ->setParent($formattedParent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); // Call the API and handle any network failures. try { /** @var OperationResponse $response */ - $response = $dataLabelingServiceClient->labelVideo($formattedParent, $basicConfig, $feature); + $response = $dataLabelingServiceClient->labelVideo($request); $response->pollUntilComplete(); if ($response->operationSucceeded()) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotated_datasets.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotated_datasets.php index 74ab27c8f908..626a39520506 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotated_datasets.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotated_datasets.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\ListAnnotatedDatasetsRequest; /** * Lists annotated datasets for a dataset. Pagination is supported. @@ -40,10 +41,14 @@ function list_annotated_datasets_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListAnnotatedDatasetsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listAnnotatedDatasets($formattedParent); + $response = $dataLabelingServiceClient->listAnnotatedDatasets($request); /** @var AnnotatedDataset $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotation_spec_sets.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotation_spec_sets.php index 6f39d820fae3..2fd5ef4f69c1 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotation_spec_sets.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_annotation_spec_sets.php @@ -26,7 +26,8 @@ use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; use Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\ListAnnotationSpecSetsRequest; /** * Lists annotation spec sets for a project. Pagination is supported. @@ -40,10 +41,14 @@ function list_annotation_spec_sets_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListAnnotationSpecSetsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listAnnotationSpecSets($formattedParent); + $response = $dataLabelingServiceClient->listAnnotationSpecSets($request); /** @var AnnotationSpecSet $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_data_items.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_data_items.php index ac3b5f5ccf64..00ac1495230e 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_data_items.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_data_items.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ListDataItems_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\DataItem; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\ListDataItemsRequest; /** * Lists data items in a dataset. This API can be called after data @@ -41,10 +42,14 @@ function list_data_items_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListDataItemsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listDataItems($formattedParent); + $response = $dataLabelingServiceClient->listDataItems($request); /** @var DataItem $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_datasets.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_datasets.php index ed74d4cbd450..043c689e598c 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_datasets.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_datasets.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ListDatasets_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Dataset; +use Google\Cloud\DataLabeling\V1beta1\ListDatasetsRequest; /** * Lists datasets under a project. Pagination is supported. @@ -40,10 +41,14 @@ function list_datasets_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListDatasetsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listDatasets($formattedParent); + $response = $dataLabelingServiceClient->listDatasets($request); /** @var Dataset $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_evaluation_jobs.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_evaluation_jobs.php index 4e97685c38c3..e2b7147b8335 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_evaluation_jobs.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_evaluation_jobs.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ListEvaluationJobs_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\EvaluationJob; +use Google\Cloud\DataLabeling\V1beta1\ListEvaluationJobsRequest; /** * Lists all evaluation jobs within a project with possible filters. @@ -41,10 +42,14 @@ function list_evaluation_jobs_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListEvaluationJobsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listEvaluationJobs($formattedParent); + $response = $dataLabelingServiceClient->listEvaluationJobs($request); /** @var EvaluationJob $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_examples.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_examples.php index 3c363a768b7e..ebdd7c6417be 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_examples.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_examples.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ListExamples_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Example; +use Google\Cloud\DataLabeling\V1beta1\ListExamplesRequest; /** * Lists examples in an annotated dataset. Pagination is supported. @@ -39,10 +40,14 @@ function list_examples_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListExamplesRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listExamples($formattedParent); + $response = $dataLabelingServiceClient->listExamples($request); /** @var Example $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_instructions.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_instructions.php index 51a41a265c42..e2a60ee9bd13 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_instructions.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/list_instructions.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ListInstructions_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Instruction; +use Google\Cloud\DataLabeling\V1beta1\ListInstructionsRequest; /** * Lists instructions for a project. Pagination is supported. @@ -40,10 +41,14 @@ function list_instructions_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ListInstructionsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->listInstructions($formattedParent); + $response = $dataLabelingServiceClient->listInstructions($request); /** @var Instruction $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/pause_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/pause_evaluation_job.php index 28f3d5ac0234..37cfca70a324 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/pause_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/pause_evaluation_job.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_PauseEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\PauseEvaluationJobRequest; /** * Pauses an evaluation job. Pausing an evaluation job that is already in a @@ -40,9 +41,13 @@ function pause_evaluation_job_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new PauseEvaluationJobRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->pauseEvaluationJob($formattedName); + $dataLabelingServiceClient->pauseEvaluationJob($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/resume_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/resume_evaluation_job.php index 5cc27e1669f1..88708a65b642 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/resume_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/resume_evaluation_job.php @@ -24,7 +24,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_ResumeEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\ResumeEvaluationJobRequest; /** * Resumes a paused evaluation job. A deleted evaluation job can't be resumed. @@ -40,9 +41,13 @@ function resume_evaluation_job_sample(string $formattedName): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new ResumeEvaluationJobRequest()) + ->setName($formattedName); + // Call the API and handle any network failures. try { - $dataLabelingServiceClient->resumeEvaluationJob($formattedName); + $dataLabelingServiceClient->resumeEvaluationJob($request); printf('Call completed successfully.' . PHP_EOL); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_evaluations.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_evaluations.php index 19cce4791d93..a2a549d5c7d8 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_evaluations.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_evaluations.php @@ -25,8 +25,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_SearchEvaluations_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\Evaluation; +use Google\Cloud\DataLabeling\V1beta1\SearchEvaluationsRequest; /** * Searches [evaluations][google.cloud.datalabeling.v1beta1.Evaluation] within a project. @@ -40,10 +41,14 @@ function search_evaluations_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new SearchEvaluationsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->searchEvaluations($formattedParent); + $response = $dataLabelingServiceClient->searchEvaluations($request); /** @var Evaluation $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_example_comparisons.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_example_comparisons.php index 360fd9b80bf0..b72c77f1283e 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_example_comparisons.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/search_example_comparisons.php @@ -25,7 +25,8 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_SearchExampleComparisons_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\SearchExampleComparisonsRequest; use Google\Cloud\DataLabeling\V1beta1\SearchExampleComparisonsResponse\ExampleComparison; /** @@ -44,10 +45,14 @@ function search_example_comparisons_sample(string $formattedParent): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); + // Prepare the request message. + $request = (new SearchExampleComparisonsRequest()) + ->setParent($formattedParent); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $dataLabelingServiceClient->searchExampleComparisons($formattedParent); + $response = $dataLabelingServiceClient->searchExampleComparisons($request); /** @var ExampleComparison $element */ foreach ($response as $element) { diff --git a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/update_evaluation_job.php b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/update_evaluation_job.php index b8a360bbce19..ca30b25661f1 100644 --- a/DataLabeling/samples/V1beta1/DataLabelingServiceClient/update_evaluation_job.php +++ b/DataLabeling/samples/V1beta1/DataLabelingServiceClient/update_evaluation_job.php @@ -24,8 +24,9 @@ // [START datalabeling_v1beta1_generated_DataLabelingService_UpdateEvaluationJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\DataLabeling\V1beta1\DataLabelingServiceClient; +use Google\Cloud\DataLabeling\V1beta1\Client\DataLabelingServiceClient; use Google\Cloud\DataLabeling\V1beta1\EvaluationJob; +use Google\Cloud\DataLabeling\V1beta1\UpdateEvaluationJobRequest; /** * Updates an evaluation job. You can only update certain fields of the job's @@ -46,13 +47,15 @@ function update_evaluation_job_sample(): void // Create a client. $dataLabelingServiceClient = new DataLabelingServiceClient(); - // Prepare any non-scalar elements to be passed along with the request. + // Prepare the request message. $evaluationJob = new EvaluationJob(); + $request = (new UpdateEvaluationJobRequest()) + ->setEvaluationJob($evaluationJob); // Call the API and handle any network failures. try { /** @var EvaluationJob $response */ - $response = $dataLabelingServiceClient->updateEvaluationJob($evaluationJob); + $response = $dataLabelingServiceClient->updateEvaluationJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/Client/BaseClient/DataLabelingServiceBaseClient.php b/DataLabeling/src/V1beta1/Client/BaseClient/DataLabelingServiceBaseClient.php similarity index 100% rename from owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/Client/BaseClient/DataLabelingServiceBaseClient.php rename to DataLabeling/src/V1beta1/Client/BaseClient/DataLabelingServiceBaseClient.php diff --git a/owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/Client/DataLabelingServiceClient.php b/DataLabeling/src/V1beta1/Client/DataLabelingServiceClient.php similarity index 100% rename from owl-bot-staging/DataLabeling/v1beta1/src/V1beta1/Client/DataLabelingServiceClient.php rename to DataLabeling/src/V1beta1/Client/DataLabelingServiceClient.php diff --git a/DataLabeling/src/V1beta1/CreateAnnotationSpecSetRequest.php b/DataLabeling/src/V1beta1/CreateAnnotationSpecSetRequest.php index 904e92d08e62..3434647cb844 100644 --- a/DataLabeling/src/V1beta1/CreateAnnotationSpecSetRequest.php +++ b/DataLabeling/src/V1beta1/CreateAnnotationSpecSetRequest.php @@ -31,6 +31,25 @@ class CreateAnnotationSpecSetRequest extends \Google\Protobuf\Internal\Message */ private $annotation_spec_set = null; + /** + * @param string $parent Required. AnnotationSpecSet resource parent, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet $annotationSpecSet Required. Annotation spec set to create. Annotation specs must be included. + * Only one annotation spec will be accepted for annotation specs with same + * display_name. + * + * @return \Google\Cloud\DataLabeling\V1beta1\CreateAnnotationSpecSetRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet $annotationSpecSet): self + { + return (new self()) + ->setParent($parent) + ->setAnnotationSpecSet($annotationSpecSet); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/CreateDatasetRequest.php b/DataLabeling/src/V1beta1/CreateDatasetRequest.php index 24ba6a8815a7..c18ce558f4a4 100644 --- a/DataLabeling/src/V1beta1/CreateDatasetRequest.php +++ b/DataLabeling/src/V1beta1/CreateDatasetRequest.php @@ -29,6 +29,23 @@ class CreateDatasetRequest extends \Google\Protobuf\Internal\Message */ private $dataset = null; + /** + * @param string $parent Required. Dataset resource parent, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\Dataset $dataset Required. The dataset to be created. + * + * @return \Google\Cloud\DataLabeling\V1beta1\CreateDatasetRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\Dataset $dataset): self + { + return (new self()) + ->setParent($parent) + ->setDataset($dataset); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/CreateEvaluationJobRequest.php b/DataLabeling/src/V1beta1/CreateEvaluationJobRequest.php index 972195368d03..9fa7efa1e631 100644 --- a/DataLabeling/src/V1beta1/CreateEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/CreateEvaluationJobRequest.php @@ -29,6 +29,23 @@ class CreateEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $job = null; + /** + * @param string $parent Required. Evaluation job resource parent. Format: + * "projects/{project_id}" + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\EvaluationJob $job Required. The evaluation job to create. + * + * @return \Google\Cloud\DataLabeling\V1beta1\CreateEvaluationJobRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\EvaluationJob $job): self + { + return (new self()) + ->setParent($parent) + ->setJob($job); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/CreateInstructionRequest.php b/DataLabeling/src/V1beta1/CreateInstructionRequest.php index 21d8d99707c9..919befc4c3da 100644 --- a/DataLabeling/src/V1beta1/CreateInstructionRequest.php +++ b/DataLabeling/src/V1beta1/CreateInstructionRequest.php @@ -29,6 +29,23 @@ class CreateInstructionRequest extends \Google\Protobuf\Internal\Message */ private $instruction = null; + /** + * @param string $parent Required. Instruction resource parent, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\Instruction $instruction Required. Instruction of how to perform the labeling task. + * + * @return \Google\Cloud\DataLabeling\V1beta1\CreateInstructionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\Instruction $instruction): self + { + return (new self()) + ->setParent($parent) + ->setInstruction($instruction); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/DeleteAnnotationSpecSetRequest.php b/DataLabeling/src/V1beta1/DeleteAnnotationSpecSetRequest.php index d58db6aa7512..b716be238531 100644 --- a/DataLabeling/src/V1beta1/DeleteAnnotationSpecSetRequest.php +++ b/DataLabeling/src/V1beta1/DeleteAnnotationSpecSetRequest.php @@ -23,6 +23,21 @@ class DeleteAnnotationSpecSetRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. AnnotationSpec resource name, format: + * `projects/{project_id}/annotationSpecSets/{annotation_spec_set_id}`. Please see + * {@see DataLabelingServiceClient::annotationSpecSetName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\DeleteAnnotationSpecSetRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/DeleteDatasetRequest.php b/DataLabeling/src/V1beta1/DeleteDatasetRequest.php index ac59793f9e8f..6ecfa33b05d9 100644 --- a/DataLabeling/src/V1beta1/DeleteDatasetRequest.php +++ b/DataLabeling/src/V1beta1/DeleteDatasetRequest.php @@ -23,6 +23,21 @@ class DeleteDatasetRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Dataset resource name, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\DeleteDatasetRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/DeleteEvaluationJobRequest.php b/DataLabeling/src/V1beta1/DeleteEvaluationJobRequest.php index 0037c21ad02a..36717ee41a8c 100644 --- a/DataLabeling/src/V1beta1/DeleteEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/DeleteEvaluationJobRequest.php @@ -23,6 +23,22 @@ class DeleteEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the evaluation job that is going to be deleted. Format: + * + * "projects/{project_id}/evaluationJobs/{evaluation_job_id}" + * Please see {@see DataLabelingServiceClient::evaluationJobName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\DeleteEvaluationJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/DeleteInstructionRequest.php b/DataLabeling/src/V1beta1/DeleteInstructionRequest.php index 4bf57189fb34..a6ff7a5b98cd 100644 --- a/DataLabeling/src/V1beta1/DeleteInstructionRequest.php +++ b/DataLabeling/src/V1beta1/DeleteInstructionRequest.php @@ -23,6 +23,21 @@ class DeleteInstructionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Instruction resource name, format: + * projects/{project_id}/instructions/{instruction_id} + * Please see {@see DataLabelingServiceClient::instructionName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\DeleteInstructionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ExportDataRequest.php b/DataLabeling/src/V1beta1/ExportDataRequest.php index 71fdb7789502..190912b7f317 100644 --- a/DataLabeling/src/V1beta1/ExportDataRequest.php +++ b/DataLabeling/src/V1beta1/ExportDataRequest.php @@ -52,6 +52,32 @@ class ExportDataRequest extends \Google\Protobuf\Internal\Message */ private $user_email_address = ''; + /** + * @param string $name Required. Dataset resource name, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param string $annotatedDataset Required. Annotated dataset resource name. DataItem in + * Dataset and their annotations in specified annotated dataset will be + * exported. It's in format of + * projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ + * {annotated_dataset_id} + * Please see {@see DataLabelingServiceClient::annotatedDatasetName()} for help formatting this field. + * @param string $filter Optional. Filter is not supported at this moment. + * @param \Google\Cloud\DataLabeling\V1beta1\OutputConfig $outputConfig Required. Specify the output destination. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ExportDataRequest + * + * @experimental + */ + public static function build(string $name, string $annotatedDataset, string $filter, \Google\Cloud\DataLabeling\V1beta1\OutputConfig $outputConfig): self + { + return (new self()) + ->setName($name) + ->setAnnotatedDataset($annotatedDataset) + ->setFilter($filter) + ->setOutputConfig($outputConfig); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetAnnotatedDatasetRequest.php b/DataLabeling/src/V1beta1/GetAnnotatedDatasetRequest.php index c2ddad38e9a9..61db39c8958a 100644 --- a/DataLabeling/src/V1beta1/GetAnnotatedDatasetRequest.php +++ b/DataLabeling/src/V1beta1/GetAnnotatedDatasetRequest.php @@ -24,6 +24,22 @@ class GetAnnotatedDatasetRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the annotated dataset to get, format: + * projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ + * {annotated_dataset_id} + * Please see {@see DataLabelingServiceClient::annotatedDatasetName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetAnnotatedDatasetRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetAnnotationSpecSetRequest.php b/DataLabeling/src/V1beta1/GetAnnotationSpecSetRequest.php index ffb3a4cea2c6..ec888645d6f2 100644 --- a/DataLabeling/src/V1beta1/GetAnnotationSpecSetRequest.php +++ b/DataLabeling/src/V1beta1/GetAnnotationSpecSetRequest.php @@ -23,6 +23,21 @@ class GetAnnotationSpecSetRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. AnnotationSpecSet resource name, format: + * projects/{project_id}/annotationSpecSets/{annotation_spec_set_id} + * Please see {@see DataLabelingServiceClient::annotationSpecSetName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetAnnotationSpecSetRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetDataItemRequest.php b/DataLabeling/src/V1beta1/GetDataItemRequest.php index 709d6c01b046..64cf5bed8eee 100644 --- a/DataLabeling/src/V1beta1/GetDataItemRequest.php +++ b/DataLabeling/src/V1beta1/GetDataItemRequest.php @@ -23,6 +23,21 @@ class GetDataItemRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. The name of the data item to get, format: + * projects/{project_id}/datasets/{dataset_id}/dataItems/{data_item_id} + * Please see {@see DataLabelingServiceClient::dataItemName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetDataItemRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetDatasetRequest.php b/DataLabeling/src/V1beta1/GetDatasetRequest.php index eaf6eb71da93..ce15722e551d 100644 --- a/DataLabeling/src/V1beta1/GetDatasetRequest.php +++ b/DataLabeling/src/V1beta1/GetDatasetRequest.php @@ -23,6 +23,21 @@ class GetDatasetRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Dataset resource name, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetDatasetRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetEvaluationJobRequest.php b/DataLabeling/src/V1beta1/GetEvaluationJobRequest.php index 0809cad4c414..c8679c91079e 100644 --- a/DataLabeling/src/V1beta1/GetEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/GetEvaluationJobRequest.php @@ -23,6 +23,22 @@ class GetEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the evaluation job. Format: + * + * "projects/{project_id}/evaluationJobs/{evaluation_job_id}" + * Please see {@see DataLabelingServiceClient::evaluationJobName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetEvaluationJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetEvaluationRequest.php b/DataLabeling/src/V1beta1/GetEvaluationRequest.php index 10ea11a07248..fe3dae048735 100644 --- a/DataLabeling/src/V1beta1/GetEvaluationRequest.php +++ b/DataLabeling/src/V1beta1/GetEvaluationRequest.php @@ -23,6 +23,22 @@ class GetEvaluationRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the evaluation. Format: + * + * "projects/{project_id}/datasets/{dataset_id}/evaluations/{evaluation_id}' + * Please see {@see DataLabelingServiceClient::evaluationName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetEvaluationRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetExampleRequest.php b/DataLabeling/src/V1beta1/GetExampleRequest.php index 2ecde5032735..a501296de8e5 100644 --- a/DataLabeling/src/V1beta1/GetExampleRequest.php +++ b/DataLabeling/src/V1beta1/GetExampleRequest.php @@ -32,6 +32,26 @@ class GetExampleRequest extends \Google\Protobuf\Internal\Message */ private $filter = ''; + /** + * @param string $name Required. Name of example, format: + * projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ + * {annotated_dataset_id}/examples/{example_id} + * Please see {@see DataLabelingServiceClient::exampleName()} for help formatting this field. + * @param string $filter Optional. An expression for filtering Examples. Filter by + * annotation_spec.display_name is supported. Format + * "annotation_spec.display_name = {display_name}" + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetExampleRequest + * + * @experimental + */ + public static function build(string $name, string $filter): self + { + return (new self()) + ->setName($name) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/GetInstructionRequest.php b/DataLabeling/src/V1beta1/GetInstructionRequest.php index c7662aba6417..8c69ffdefbb8 100644 --- a/DataLabeling/src/V1beta1/GetInstructionRequest.php +++ b/DataLabeling/src/V1beta1/GetInstructionRequest.php @@ -23,6 +23,21 @@ class GetInstructionRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Instruction resource name, format: + * projects/{project_id}/instructions/{instruction_id} + * Please see {@see DataLabelingServiceClient::instructionName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\GetInstructionRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ImportDataRequest.php b/DataLabeling/src/V1beta1/ImportDataRequest.php index bcdbf2fb712e..e111bf578aec 100644 --- a/DataLabeling/src/V1beta1/ImportDataRequest.php +++ b/DataLabeling/src/V1beta1/ImportDataRequest.php @@ -36,6 +36,23 @@ class ImportDataRequest extends \Google\Protobuf\Internal\Message */ private $user_email_address = ''; + /** + * @param string $name Required. Dataset resource name, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\InputConfig $inputConfig Required. Specify the input source of the data. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ImportDataRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\DataLabeling\V1beta1\InputConfig $inputConfig): self + { + return (new self()) + ->setName($name) + ->setInputConfig($inputConfig); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/LabelImageRequest.php b/DataLabeling/src/V1beta1/LabelImageRequest.php index dac4b534e3cb..e71b0dad1785 100644 --- a/DataLabeling/src/V1beta1/LabelImageRequest.php +++ b/DataLabeling/src/V1beta1/LabelImageRequest.php @@ -36,6 +36,26 @@ class LabelImageRequest extends \Google\Protobuf\Internal\Message private $feature = 0; protected $request_config; + /** + * @param string $parent Required. Name of the dataset to request labeling task, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig Required. Basic human annotation config. + * @param int $feature Required. The type of image labeling task. + * For allowed values, use constants defined on {@see \Google\Cloud\DataLabeling\V1beta1\LabelImageRequest\Feature} + * + * @return \Google\Cloud\DataLabeling\V1beta1\LabelImageRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig, int $feature): self + { + return (new self()) + ->setParent($parent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/LabelTextRequest.php b/DataLabeling/src/V1beta1/LabelTextRequest.php index b3d1a610463d..92f90b20b48b 100644 --- a/DataLabeling/src/V1beta1/LabelTextRequest.php +++ b/DataLabeling/src/V1beta1/LabelTextRequest.php @@ -36,6 +36,26 @@ class LabelTextRequest extends \Google\Protobuf\Internal\Message private $feature = 0; protected $request_config; + /** + * @param string $parent Required. Name of the data set to request labeling task, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig Required. Basic human annotation config. + * @param int $feature Required. The type of text labeling task. + * For allowed values, use constants defined on {@see \Google\Cloud\DataLabeling\V1beta1\LabelTextRequest\Feature} + * + * @return \Google\Cloud\DataLabeling\V1beta1\LabelTextRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig, int $feature): self + { + return (new self()) + ->setParent($parent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/LabelVideoRequest.php b/DataLabeling/src/V1beta1/LabelVideoRequest.php index 35c13970dd34..79aca15869e1 100644 --- a/DataLabeling/src/V1beta1/LabelVideoRequest.php +++ b/DataLabeling/src/V1beta1/LabelVideoRequest.php @@ -36,6 +36,26 @@ class LabelVideoRequest extends \Google\Protobuf\Internal\Message private $feature = 0; protected $request_config; + /** + * @param string $parent Required. Name of the dataset to request labeling task, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig Required. Basic human annotation config. + * @param int $feature Required. The type of video labeling task. + * For allowed values, use constants defined on {@see \Google\Cloud\DataLabeling\V1beta1\LabelVideoRequest\Feature} + * + * @return \Google\Cloud\DataLabeling\V1beta1\LabelVideoRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\DataLabeling\V1beta1\HumanAnnotationConfig $basicConfig, int $feature): self + { + return (new self()) + ->setParent($parent) + ->setBasicConfig($basicConfig) + ->setFeature($feature); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListAnnotatedDatasetsRequest.php b/DataLabeling/src/V1beta1/ListAnnotatedDatasetsRequest.php index 45fe0014377a..a1c13fcd1fd5 100644 --- a/DataLabeling/src/V1beta1/ListAnnotatedDatasetsRequest.php +++ b/DataLabeling/src/V1beta1/ListAnnotatedDatasetsRequest.php @@ -46,6 +46,23 @@ class ListAnnotatedDatasetsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Name of the dataset to list annotated datasets, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param string $filter Optional. Filter is not supported at this moment. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListAnnotatedDatasetsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListAnnotationSpecSetsRequest.php b/DataLabeling/src/V1beta1/ListAnnotationSpecSetsRequest.php index b547357e6bdc..b4f725d4597c 100644 --- a/DataLabeling/src/V1beta1/ListAnnotationSpecSetsRequest.php +++ b/DataLabeling/src/V1beta1/ListAnnotationSpecSetsRequest.php @@ -46,6 +46,23 @@ class ListAnnotationSpecSetsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Parent of AnnotationSpecSet resource, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param string $filter Optional. Filter is not supported at this moment. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListAnnotationSpecSetsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListDataItemsRequest.php b/DataLabeling/src/V1beta1/ListDataItemsRequest.php index 8d199b49dfd5..f6391306e38b 100644 --- a/DataLabeling/src/V1beta1/ListDataItemsRequest.php +++ b/DataLabeling/src/V1beta1/ListDataItemsRequest.php @@ -46,6 +46,23 @@ class ListDataItemsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Name of the dataset to list data items, format: + * projects/{project_id}/datasets/{dataset_id} + * Please see {@see DataLabelingServiceClient::datasetName()} for help formatting this field. + * @param string $filter Optional. Filter is not supported at this moment. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListDataItemsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListDatasetsRequest.php b/DataLabeling/src/V1beta1/ListDatasetsRequest.php index 1640fd40ca8d..e24e98eba5a2 100644 --- a/DataLabeling/src/V1beta1/ListDatasetsRequest.php +++ b/DataLabeling/src/V1beta1/ListDatasetsRequest.php @@ -46,6 +46,23 @@ class ListDatasetsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Dataset resource parent, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param string $filter Optional. Filter on dataset is not supported at this moment. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListDatasetsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListEvaluationJobsRequest.php b/DataLabeling/src/V1beta1/ListEvaluationJobsRequest.php index ffcffc576381..7d9f4727cc78 100644 --- a/DataLabeling/src/V1beta1/ListEvaluationJobsRequest.php +++ b/DataLabeling/src/V1beta1/ListEvaluationJobsRequest.php @@ -53,6 +53,30 @@ class ListEvaluationJobsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Evaluation job resource parent. Format: + * "projects/{project_id}" + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param string $filter Optional. You can filter the jobs to list by model_id (also known as + * model_name, as described in + * [EvaluationJob.modelVersion][google.cloud.datalabeling.v1beta1.EvaluationJob.model_version]) or by + * evaluation job state (as described in [EvaluationJob.state][google.cloud.datalabeling.v1beta1.EvaluationJob.state]). To filter + * by both criteria, use the `AND` operator or the `OR` operator. For example, + * you can use the following string for your filter: + * "evaluation_job.model_id = {model_name} AND + * evaluation_job.state = {evaluation_job_state}" + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListEvaluationJobsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListExamplesRequest.php b/DataLabeling/src/V1beta1/ListExamplesRequest.php index 05128cebde83..72dde00bf404 100644 --- a/DataLabeling/src/V1beta1/ListExamplesRequest.php +++ b/DataLabeling/src/V1beta1/ListExamplesRequest.php @@ -48,6 +48,25 @@ class ListExamplesRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Example resource parent. Please see + * {@see DataLabelingServiceClient::annotatedDatasetName()} for help formatting this field. + * @param string $filter Optional. An expression for filtering Examples. For annotated datasets that + * have annotation spec set, filter by + * annotation_spec.display_name is supported. Format + * "annotation_spec.display_name = {display_name}" + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListExamplesRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ListInstructionsRequest.php b/DataLabeling/src/V1beta1/ListInstructionsRequest.php index d219fde87f7f..3e8cdaf25252 100644 --- a/DataLabeling/src/V1beta1/ListInstructionsRequest.php +++ b/DataLabeling/src/V1beta1/ListInstructionsRequest.php @@ -46,6 +46,23 @@ class ListInstructionsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Instruction resource parent, format: + * projects/{project_id} + * Please see {@see DataLabelingServiceClient::projectName()} for help formatting this field. + * @param string $filter Optional. Filter is not supported at this moment. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ListInstructionsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/PauseEvaluationJobRequest.php b/DataLabeling/src/V1beta1/PauseEvaluationJobRequest.php index 0c871857189c..e4b220b443d0 100644 --- a/DataLabeling/src/V1beta1/PauseEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/PauseEvaluationJobRequest.php @@ -23,6 +23,22 @@ class PauseEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the evaluation job that is going to be paused. Format: + * + * "projects/{project_id}/evaluationJobs/{evaluation_job_id}" + * Please see {@see DataLabelingServiceClient::evaluationJobName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\PauseEvaluationJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/ResumeEvaluationJobRequest.php b/DataLabeling/src/V1beta1/ResumeEvaluationJobRequest.php index 9ff1a685ff93..36e909eeee23 100644 --- a/DataLabeling/src/V1beta1/ResumeEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/ResumeEvaluationJobRequest.php @@ -23,6 +23,22 @@ class ResumeEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $name = ''; + /** + * @param string $name Required. Name of the evaluation job that is going to be resumed. Format: + * + * "projects/{project_id}/evaluationJobs/{evaluation_job_id}" + * Please see {@see DataLabelingServiceClient::evaluationJobName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\ResumeEvaluationJobRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/SearchEvaluationsRequest.php b/DataLabeling/src/V1beta1/SearchEvaluationsRequest.php index 604e9aff1d1f..e53f3d107197 100644 --- a/DataLabeling/src/V1beta1/SearchEvaluationsRequest.php +++ b/DataLabeling/src/V1beta1/SearchEvaluationsRequest.php @@ -74,6 +74,53 @@ class SearchEvaluationsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Evaluation search parent (project ID). Format: + * "projects/{project_id}" + * Please see {@see DataLabelingServiceClient::evaluationName()} for help formatting this field. + * @param string $filter Optional. To search evaluations, you can filter by the following: + * + * * evaluation_job.evaluation_job_id (the last part of + * [EvaluationJob.name][google.cloud.datalabeling.v1beta1.EvaluationJob.name]) + * * evaluation_job.model_id (the {model_name} portion + * of [EvaluationJob.modelVersion][google.cloud.datalabeling.v1beta1.EvaluationJob.model_version]) + * * evaluation_job.evaluation_job_run_time_start (Minimum + * threshold for the + * [evaluationJobRunTime][google.cloud.datalabeling.v1beta1.Evaluation.evaluation_job_run_time] that created + * the evaluation) + * * evaluation_job.evaluation_job_run_time_end (Maximum + * threshold for the + * [evaluationJobRunTime][google.cloud.datalabeling.v1beta1.Evaluation.evaluation_job_run_time] that created + * the evaluation) + * * evaluation_job.job_state ([EvaluationJob.state][google.cloud.datalabeling.v1beta1.EvaluationJob.state]) + * * annotation_spec.display_name (the Evaluation contains a + * metric for the annotation spec with this + * [displayName][google.cloud.datalabeling.v1beta1.AnnotationSpec.display_name]) + * + * To filter by multiple critiera, use the `AND` operator or the `OR` + * operator. The following examples shows a string that filters by several + * critiera: + * + * "evaluation_job.evaluation_job_id = + * {evaluation_job_id} AND evaluation_job.model_id = + * {model_name} AND + * evaluation_job.evaluation_job_run_time_start = + * {timestamp_1} AND + * evaluation_job.evaluation_job_run_time_end = + * {timestamp_2} AND annotation_spec.display_name = + * {display_name}" + * + * @return \Google\Cloud\DataLabeling\V1beta1\SearchEvaluationsRequest + * + * @experimental + */ + public static function build(string $parent, string $filter): self + { + return (new self()) + ->setParent($parent) + ->setFilter($filter); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/SearchExampleComparisonsRequest.php b/DataLabeling/src/V1beta1/SearchExampleComparisonsRequest.php index 31d182760ee1..50d139021b13 100644 --- a/DataLabeling/src/V1beta1/SearchExampleComparisonsRequest.php +++ b/DataLabeling/src/V1beta1/SearchExampleComparisonsRequest.php @@ -42,6 +42,23 @@ class SearchExampleComparisonsRequest extends \Google\Protobuf\Internal\Message */ private $page_token = ''; + /** + * @param string $parent Required. Name of the [Evaluation][google.cloud.datalabeling.v1beta1.Evaluation] resource to search for example + * comparisons from. Format: + * + * "projects/{project_id}/datasets/{dataset_id}/evaluations/{evaluation_id}" + * Please see {@see DataLabelingServiceClient::evaluationName()} for help formatting this field. + * + * @return \Google\Cloud\DataLabeling\V1beta1\SearchExampleComparisonsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/UpdateEvaluationJobRequest.php b/DataLabeling/src/V1beta1/UpdateEvaluationJobRequest.php index 13feff2cd161..dcefb85f98b0 100644 --- a/DataLabeling/src/V1beta1/UpdateEvaluationJobRequest.php +++ b/DataLabeling/src/V1beta1/UpdateEvaluationJobRequest.php @@ -34,6 +34,29 @@ class UpdateEvaluationJobRequest extends \Google\Protobuf\Internal\Message */ private $update_mask = null; + /** + * @param \Google\Cloud\DataLabeling\V1beta1\EvaluationJob $evaluationJob Required. Evaluation job that is going to be updated. + * @param \Google\Protobuf\FieldMask $updateMask Optional. Mask for which fields to update. You can only provide the + * following fields: + * + * * `evaluationJobConfig.humanAnnotationConfig.instruction` + * * `evaluationJobConfig.exampleCount` + * * `evaluationJobConfig.exampleSamplePercentage` + * + * You can provide more than one of these fields by separating them with + * commas. + * + * @return \Google\Cloud\DataLabeling\V1beta1\UpdateEvaluationJobRequest + * + * @experimental + */ + public static function build(\Google\Cloud\DataLabeling\V1beta1\EvaluationJob $evaluationJob, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setEvaluationJob($evaluationJob) + ->setUpdateMask($updateMask); + } + /** * Constructor. * diff --git a/DataLabeling/src/V1beta1/resources/data_labeling_service_descriptor_config.php b/DataLabeling/src/V1beta1/resources/data_labeling_service_descriptor_config.php index 33241ecd081c..56369463b2fc 100644 --- a/DataLabeling/src/V1beta1/resources/data_labeling_service_descriptor_config.php +++ b/DataLabeling/src/V1beta1/resources/data_labeling_service_descriptor_config.php @@ -12,6 +12,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ExportData' => [ 'longRunning' => [ @@ -22,6 +31,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ImportData' => [ 'longRunning' => [ @@ -32,6 +50,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'LabelImage' => [ 'longRunning' => [ @@ -42,6 +69,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'LabelText' => [ 'longRunning' => [ @@ -52,6 +88,15 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'LabelVideo' => [ 'longRunning' => [ @@ -62,6 +107,207 @@ 'maxPollDelayMillis' => '5000', 'totalPollTimeoutMillis' => '300000', ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateAnnotationSpecSet' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDataset' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\Dataset', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\EvaluationJob', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteAnnotatedDataset' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteAnnotationSpecSet' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteDataset' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteInstruction' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetAnnotatedDataset' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\AnnotatedDataset', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetAnnotationSpecSet' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\AnnotationSpecSet', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataItem' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\DataItem', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataset' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\Dataset', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetEvaluation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\Evaluation', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\EvaluationJob', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetExample' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\Example', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetInstruction' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\Instruction', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'ListAnnotatedDatasets' => [ 'pageStreaming' => [ @@ -72,6 +318,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAnnotatedDatasets', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListAnnotatedDatasetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListAnnotationSpecSets' => [ 'pageStreaming' => [ @@ -82,6 +338,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getAnnotationSpecSets', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListAnnotationSpecSetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListDataItems' => [ 'pageStreaming' => [ @@ -92,6 +358,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDataItems', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListDataItemsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListDatasets' => [ 'pageStreaming' => [ @@ -102,6 +378,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getDatasets', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListDatasetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListEvaluationJobs' => [ 'pageStreaming' => [ @@ -112,6 +398,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getEvaluationJobs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListEvaluationJobsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListExamples' => [ 'pageStreaming' => [ @@ -122,6 +418,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getExamples', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListExamplesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'ListInstructions' => [ 'pageStreaming' => [ @@ -132,6 +438,40 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getInstructions', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\ListInstructionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'PauseEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ResumeEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], ], 'SearchEvaluations' => [ 'pageStreaming' => [ @@ -142,6 +482,16 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getEvaluations', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\SearchEvaluationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], ], 'SearchExampleComparisons' => [ 'pageStreaming' => [ @@ -152,6 +502,40 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getExampleComparisons', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\SearchExampleComparisonsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateEvaluationJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\DataLabeling\V1beta1\EvaluationJob', + 'headerParams' => [ + [ + 'keyName' => 'evaluation_job.name', + 'fieldAccessors' => [ + 'getEvaluationJob', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'annotatedDataset' => 'projects/{project}/datasets/{dataset}/annotatedDatasets/{annotated_dataset}', + 'annotationSpecSet' => 'projects/{project}/annotationSpecSets/{annotation_spec_set}', + 'dataItem' => 'projects/{project}/datasets/{dataset}/dataItems/{data_item}', + 'dataset' => 'projects/{project}/datasets/{dataset}', + 'evaluation' => 'projects/{project}/datasets/{dataset}/evaluations/{evaluation}', + 'evaluationJob' => 'projects/{project}/evaluationJobs/{evaluation_job}', + 'example' => 'projects/{project}/datasets/{dataset}/annotatedDatasets/{annotated_dataset}/examples/{example}', + 'instruction' => 'projects/{project}/instructions/{instruction}', + 'project' => 'projects/{project}', ], ], ], diff --git a/owl-bot-staging/DataLabeling/v1beta1/tests/Unit/V1beta1/Client/DataLabelingServiceClientTest.php b/DataLabeling/tests/Unit/V1beta1/Client/DataLabelingServiceClientTest.php similarity index 100% rename from owl-bot-staging/DataLabeling/v1beta1/tests/Unit/V1beta1/Client/DataLabelingServiceClientTest.php rename to DataLabeling/tests/Unit/V1beta1/Client/DataLabelingServiceClientTest.php diff --git a/Dataflow/samples/V1beta3/FlexTemplatesServiceClient/launch_flex_template.php b/Dataflow/samples/V1beta3/FlexTemplatesServiceClient/launch_flex_template.php index 8f9e12c76ba1..97dbc8d2843d 100644 --- a/Dataflow/samples/V1beta3/FlexTemplatesServiceClient/launch_flex_template.php +++ b/Dataflow/samples/V1beta3/FlexTemplatesServiceClient/launch_flex_template.php @@ -24,7 +24,8 @@ // [START dataflow_v1beta3_generated_FlexTemplatesService_LaunchFlexTemplate_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Dataflow\V1beta3\FlexTemplatesServiceClient; +use Google\Cloud\Dataflow\V1beta3\Client\FlexTemplatesServiceClient; +use Google\Cloud\Dataflow\V1beta3\LaunchFlexTemplateRequest; use Google\Cloud\Dataflow\V1beta3\LaunchFlexTemplateResponse; /** @@ -41,10 +42,13 @@ function launch_flex_template_sample(): void // Create a client. $flexTemplatesServiceClient = new FlexTemplatesServiceClient(); + // Prepare the request message. + $request = new LaunchFlexTemplateRequest(); + // Call the API and handle any network failures. try { /** @var LaunchFlexTemplateResponse $response */ - $response = $flexTemplatesServiceClient->launchFlexTemplate(); + $response = $flexTemplatesServiceClient->launchFlexTemplate($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/aggregated_list_jobs.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/aggregated_list_jobs.php index 70a3b0ba21f4..4322ced6701b 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/aggregated_list_jobs.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/aggregated_list_jobs.php @@ -25,8 +25,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_AggregatedListJobs_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\ListJobsRequest; /** * List the jobs of a project across all regions. @@ -42,10 +43,13 @@ function aggregated_list_jobs_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new ListJobsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $jobsV1Beta3Client->aggregatedListJobs(); + $response = $jobsV1Beta3Client->aggregatedListJobs($request); /** @var Job $element */ foreach ($response as $element) { diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/check_active_jobs.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/check_active_jobs.php index def664221fe3..bc9fc4e85e7e 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/check_active_jobs.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/check_active_jobs.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_CheckActiveJobs_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\CheckActiveJobsRequest; use Google\Cloud\Dataflow\V1beta3\CheckActiveJobsResponse; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; /** * Check for existence of active jobs in the given project across all regions. @@ -41,10 +42,13 @@ function check_active_jobs_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new CheckActiveJobsRequest(); + // Call the API and handle any network failures. try { /** @var CheckActiveJobsResponse $response */ - $response = $jobsV1Beta3Client->checkActiveJobs(); + $response = $jobsV1Beta3Client->checkActiveJobs($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/create_job.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/create_job.php index 91ac3e42b2be..07146dcd10b7 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/create_job.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/create_job.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_CreateJob_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\CreateJobRequest; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; /** * Creates a Cloud Dataflow job. @@ -47,10 +48,13 @@ function create_job_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new CreateJobRequest(); + // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $jobsV1Beta3Client->createJob(); + $response = $jobsV1Beta3Client->createJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/get_job.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/get_job.php index b947155fc30e..71404ef478e0 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/get_job.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/get_job.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_GetJob_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\GetJobRequest; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; /** * Gets the state of the specified Cloud Dataflow job. @@ -47,10 +48,13 @@ function get_job_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new GetJobRequest(); + // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $jobsV1Beta3Client->getJob(); + $response = $jobsV1Beta3Client->getJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/list_jobs.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/list_jobs.php index d8d109e94a06..75b2ba00ccb2 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/list_jobs.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/list_jobs.php @@ -25,8 +25,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_ListJobs_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\ListJobsRequest; /** * List the jobs of a project. @@ -49,10 +50,13 @@ function list_jobs_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new ListJobsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $jobsV1Beta3Client->listJobs(); + $response = $jobsV1Beta3Client->listJobs($request); /** @var Job $element */ foreach ($response as $element) { diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/snapshot_job.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/snapshot_job.php index edb37112b527..6f542c0e7d08 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/snapshot_job.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/snapshot_job.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_SnapshotJob_sync] use Google\ApiCore\ApiException; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; use Google\Cloud\Dataflow\V1beta3\Snapshot; +use Google\Cloud\Dataflow\V1beta3\SnapshotJobRequest; /** * Snapshot the state of a streaming job. @@ -41,10 +42,13 @@ function snapshot_job_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new SnapshotJobRequest(); + // Call the API and handle any network failures. try { /** @var Snapshot $response */ - $response = $jobsV1Beta3Client->snapshotJob(); + $response = $jobsV1Beta3Client->snapshotJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/JobsV1Beta3Client/update_job.php b/Dataflow/samples/V1beta3/JobsV1Beta3Client/update_job.php index 616d31441267..4f08f4bd9a23 100644 --- a/Dataflow/samples/V1beta3/JobsV1Beta3Client/update_job.php +++ b/Dataflow/samples/V1beta3/JobsV1Beta3Client/update_job.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_JobsV1Beta3_UpdateJob_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\JobsV1Beta3Client; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\JobsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\UpdateJobRequest; /** * Updates the state of an existing Cloud Dataflow job. @@ -47,10 +48,13 @@ function update_job_sample(): void // Create a client. $jobsV1Beta3Client = new JobsV1Beta3Client(); + // Prepare the request message. + $request = new UpdateJobRequest(); + // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $jobsV1Beta3Client->updateJob(); + $response = $jobsV1Beta3Client->updateJob($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/MessagesV1Beta3Client/list_job_messages.php b/Dataflow/samples/V1beta3/MessagesV1Beta3Client/list_job_messages.php index ab04eb4f8a67..16f7060f7514 100644 --- a/Dataflow/samples/V1beta3/MessagesV1Beta3Client/list_job_messages.php +++ b/Dataflow/samples/V1beta3/MessagesV1Beta3Client/list_job_messages.php @@ -25,8 +25,9 @@ // [START dataflow_v1beta3_generated_MessagesV1Beta3_ListJobMessages_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; +use Google\Cloud\Dataflow\V1beta3\Client\MessagesV1Beta3Client; use Google\Cloud\Dataflow\V1beta3\JobMessage; -use Google\Cloud\Dataflow\V1beta3\MessagesV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\ListJobMessagesRequest; /** * Request the job status. @@ -48,10 +49,13 @@ function list_job_messages_sample(): void // Create a client. $messagesV1Beta3Client = new MessagesV1Beta3Client(); + // Prepare the request message. + $request = new ListJobMessagesRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $messagesV1Beta3Client->listJobMessages(); + $response = $messagesV1Beta3Client->listJobMessages($request); /** @var JobMessage $element */ foreach ($response as $element) { diff --git a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_execution_details.php b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_execution_details.php index 48cdbc5f4aec..c74acf17fac6 100644 --- a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_execution_details.php +++ b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_execution_details.php @@ -25,7 +25,8 @@ // [START dataflow_v1beta3_generated_MetricsV1Beta3_GetJobExecutionDetails_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\Dataflow\V1beta3\MetricsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\Client\MetricsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\GetJobExecutionDetailsRequest; use Google\Cloud\Dataflow\V1beta3\StageSummary; /** @@ -44,10 +45,13 @@ function get_job_execution_details_sample(): void // Create a client. $metricsV1Beta3Client = new MetricsV1Beta3Client(); + // Prepare the request message. + $request = new GetJobExecutionDetailsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $metricsV1Beta3Client->getJobExecutionDetails(); + $response = $metricsV1Beta3Client->getJobExecutionDetails($request); /** @var StageSummary $element */ foreach ($response as $element) { diff --git a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_metrics.php b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_metrics.php index 5cf134e3db76..681decd41792 100644 --- a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_metrics.php +++ b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_job_metrics.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_MetricsV1Beta3_GetJobMetrics_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\MetricsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\GetJobMetricsRequest; use Google\Cloud\Dataflow\V1beta3\JobMetrics; -use Google\Cloud\Dataflow\V1beta3\MetricsV1Beta3Client; /** * Request the job status. @@ -47,10 +48,13 @@ function get_job_metrics_sample(): void // Create a client. $metricsV1Beta3Client = new MetricsV1Beta3Client(); + // Prepare the request message. + $request = new GetJobMetricsRequest(); + // Call the API and handle any network failures. try { /** @var JobMetrics $response */ - $response = $metricsV1Beta3Client->getJobMetrics(); + $response = $metricsV1Beta3Client->getJobMetrics($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_stage_execution_details.php b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_stage_execution_details.php index 555a59df76df..285bc8d788c5 100644 --- a/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_stage_execution_details.php +++ b/Dataflow/samples/V1beta3/MetricsV1Beta3Client/get_stage_execution_details.php @@ -25,7 +25,8 @@ // [START dataflow_v1beta3_generated_MetricsV1Beta3_GetStageExecutionDetails_sync] use Google\ApiCore\ApiException; use Google\ApiCore\PagedListResponse; -use Google\Cloud\Dataflow\V1beta3\MetricsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\Client\MetricsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\GetStageExecutionDetailsRequest; use Google\Cloud\Dataflow\V1beta3\WorkerDetails; /** @@ -45,10 +46,13 @@ function get_stage_execution_details_sample(): void // Create a client. $metricsV1Beta3Client = new MetricsV1Beta3Client(); + // Prepare the request message. + $request = new GetStageExecutionDetailsRequest(); + // Call the API and handle any network failures. try { /** @var PagedListResponse $response */ - $response = $metricsV1Beta3Client->getStageExecutionDetails(); + $response = $metricsV1Beta3Client->getStageExecutionDetails($request); /** @var WorkerDetails $element */ foreach ($response as $element) { diff --git a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/delete_snapshot.php b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/delete_snapshot.php index 5272f00956fb..467dedbe6600 100644 --- a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/delete_snapshot.php +++ b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/delete_snapshot.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_SnapshotsV1Beta3_DeleteSnapshot_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\SnapshotsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\DeleteSnapshotRequest; use Google\Cloud\Dataflow\V1beta3\DeleteSnapshotResponse; -use Google\Cloud\Dataflow\V1beta3\SnapshotsV1Beta3Client; /** * Deletes a snapshot. @@ -41,10 +42,13 @@ function delete_snapshot_sample(): void // Create a client. $snapshotsV1Beta3Client = new SnapshotsV1Beta3Client(); + // Prepare the request message. + $request = new DeleteSnapshotRequest(); + // Call the API and handle any network failures. try { /** @var DeleteSnapshotResponse $response */ - $response = $snapshotsV1Beta3Client->deleteSnapshot(); + $response = $snapshotsV1Beta3Client->deleteSnapshot($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/get_snapshot.php b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/get_snapshot.php index f65ec68a8fd2..6f28b4ff6a61 100644 --- a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/get_snapshot.php +++ b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/get_snapshot.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_SnapshotsV1Beta3_GetSnapshot_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\SnapshotsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\GetSnapshotRequest; use Google\Cloud\Dataflow\V1beta3\Snapshot; -use Google\Cloud\Dataflow\V1beta3\SnapshotsV1Beta3Client; /** * Gets information about a snapshot. @@ -41,10 +42,13 @@ function get_snapshot_sample(): void // Create a client. $snapshotsV1Beta3Client = new SnapshotsV1Beta3Client(); + // Prepare the request message. + $request = new GetSnapshotRequest(); + // Call the API and handle any network failures. try { /** @var Snapshot $response */ - $response = $snapshotsV1Beta3Client->getSnapshot(); + $response = $snapshotsV1Beta3Client->getSnapshot($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/list_snapshots.php b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/list_snapshots.php index 4b5839939e50..31a8cb6786ec 100644 --- a/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/list_snapshots.php +++ b/Dataflow/samples/V1beta3/SnapshotsV1Beta3Client/list_snapshots.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_SnapshotsV1Beta3_ListSnapshots_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\SnapshotsV1Beta3Client; +use Google\Cloud\Dataflow\V1beta3\ListSnapshotsRequest; use Google\Cloud\Dataflow\V1beta3\ListSnapshotsResponse; -use Google\Cloud\Dataflow\V1beta3\SnapshotsV1Beta3Client; /** * Lists snapshots. @@ -41,10 +42,13 @@ function list_snapshots_sample(): void // Create a client. $snapshotsV1Beta3Client = new SnapshotsV1Beta3Client(); + // Prepare the request message. + $request = new ListSnapshotsRequest(); + // Call the API and handle any network failures. try { /** @var ListSnapshotsResponse $response */ - $response = $snapshotsV1Beta3Client->listSnapshots(); + $response = $snapshotsV1Beta3Client->listSnapshots($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/TemplatesServiceClient/create_job_from_template.php b/Dataflow/samples/V1beta3/TemplatesServiceClient/create_job_from_template.php index 2012a20bf51c..b87e9b36a1d1 100644 --- a/Dataflow/samples/V1beta3/TemplatesServiceClient/create_job_from_template.php +++ b/Dataflow/samples/V1beta3/TemplatesServiceClient/create_job_from_template.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_TemplatesService_CreateJobFromTemplate_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\TemplatesServiceClient; +use Google\Cloud\Dataflow\V1beta3\CreateJobFromTemplateRequest; use Google\Cloud\Dataflow\V1beta3\Job; -use Google\Cloud\Dataflow\V1beta3\TemplatesServiceClient; /** * Creates a Cloud Dataflow job from a template. @@ -41,10 +42,13 @@ function create_job_from_template_sample(): void // Create a client. $templatesServiceClient = new TemplatesServiceClient(); + // Prepare the request message. + $request = new CreateJobFromTemplateRequest(); + // Call the API and handle any network failures. try { /** @var Job $response */ - $response = $templatesServiceClient->createJobFromTemplate(); + $response = $templatesServiceClient->createJobFromTemplate($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/TemplatesServiceClient/get_template.php b/Dataflow/samples/V1beta3/TemplatesServiceClient/get_template.php index e134c685b868..46e32eabace6 100644 --- a/Dataflow/samples/V1beta3/TemplatesServiceClient/get_template.php +++ b/Dataflow/samples/V1beta3/TemplatesServiceClient/get_template.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_TemplatesService_GetTemplate_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\TemplatesServiceClient; +use Google\Cloud\Dataflow\V1beta3\GetTemplateRequest; use Google\Cloud\Dataflow\V1beta3\GetTemplateResponse; -use Google\Cloud\Dataflow\V1beta3\TemplatesServiceClient; /** * Get the template associated with a template. @@ -41,10 +42,13 @@ function get_template_sample(): void // Create a client. $templatesServiceClient = new TemplatesServiceClient(); + // Prepare the request message. + $request = new GetTemplateRequest(); + // Call the API and handle any network failures. try { /** @var GetTemplateResponse $response */ - $response = $templatesServiceClient->getTemplate(); + $response = $templatesServiceClient->getTemplate($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/Dataflow/samples/V1beta3/TemplatesServiceClient/launch_template.php b/Dataflow/samples/V1beta3/TemplatesServiceClient/launch_template.php index 040a60aa0ad0..d08fb198d649 100644 --- a/Dataflow/samples/V1beta3/TemplatesServiceClient/launch_template.php +++ b/Dataflow/samples/V1beta3/TemplatesServiceClient/launch_template.php @@ -24,8 +24,9 @@ // [START dataflow_v1beta3_generated_TemplatesService_LaunchTemplate_sync] use Google\ApiCore\ApiException; +use Google\Cloud\Dataflow\V1beta3\Client\TemplatesServiceClient; +use Google\Cloud\Dataflow\V1beta3\LaunchTemplateRequest; use Google\Cloud\Dataflow\V1beta3\LaunchTemplateResponse; -use Google\Cloud\Dataflow\V1beta3\TemplatesServiceClient; /** * Launch a template. @@ -41,10 +42,13 @@ function launch_template_sample(): void // Create a client. $templatesServiceClient = new TemplatesServiceClient(); + // Prepare the request message. + $request = new LaunchTemplateRequest(); + // Call the API and handle any network failures. try { /** @var LaunchTemplateResponse $response */ - $response = $templatesServiceClient->launchTemplate(); + $response = $templatesServiceClient->launchTemplate($request); printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); } catch (ApiException $ex) { printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/FlexTemplatesServiceBaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/FlexTemplatesServiceBaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/FlexTemplatesServiceBaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/FlexTemplatesServiceBaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/JobsV1Beta3BaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/JobsV1Beta3BaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/JobsV1Beta3BaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/JobsV1Beta3BaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/MessagesV1Beta3BaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/MessagesV1Beta3BaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/MessagesV1Beta3BaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/MessagesV1Beta3BaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/MetricsV1Beta3BaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/MetricsV1Beta3BaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/MetricsV1Beta3BaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/MetricsV1Beta3BaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/SnapshotsV1Beta3BaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/SnapshotsV1Beta3BaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/SnapshotsV1Beta3BaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/SnapshotsV1Beta3BaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/TemplatesServiceBaseClient.php b/Dataflow/src/V1beta3/Client/BaseClient/TemplatesServiceBaseClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/BaseClient/TemplatesServiceBaseClient.php rename to Dataflow/src/V1beta3/Client/BaseClient/TemplatesServiceBaseClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/FlexTemplatesServiceClient.php b/Dataflow/src/V1beta3/Client/FlexTemplatesServiceClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/FlexTemplatesServiceClient.php rename to Dataflow/src/V1beta3/Client/FlexTemplatesServiceClient.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/JobsV1Beta3Client.php b/Dataflow/src/V1beta3/Client/JobsV1Beta3Client.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/JobsV1Beta3Client.php rename to Dataflow/src/V1beta3/Client/JobsV1Beta3Client.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/MessagesV1Beta3Client.php b/Dataflow/src/V1beta3/Client/MessagesV1Beta3Client.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/MessagesV1Beta3Client.php rename to Dataflow/src/V1beta3/Client/MessagesV1Beta3Client.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/MetricsV1Beta3Client.php b/Dataflow/src/V1beta3/Client/MetricsV1Beta3Client.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/MetricsV1Beta3Client.php rename to Dataflow/src/V1beta3/Client/MetricsV1Beta3Client.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/SnapshotsV1Beta3Client.php b/Dataflow/src/V1beta3/Client/SnapshotsV1Beta3Client.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/SnapshotsV1Beta3Client.php rename to Dataflow/src/V1beta3/Client/SnapshotsV1Beta3Client.php diff --git a/owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/TemplatesServiceClient.php b/Dataflow/src/V1beta3/Client/TemplatesServiceClient.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/src/V1beta3/Client/TemplatesServiceClient.php rename to Dataflow/src/V1beta3/Client/TemplatesServiceClient.php diff --git a/Dataflow/src/V1beta3/resources/flex_templates_service_descriptor_config.php b/Dataflow/src/V1beta3/resources/flex_templates_service_descriptor_config.php index d437a66d22ce..215fe9e2c16e 100644 --- a/Dataflow/src/V1beta3/resources/flex_templates_service_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/flex_templates_service_descriptor_config.php @@ -2,6 +2,25 @@ return [ 'interfaces' => [ - 'google.dataflow.v1beta3.FlexTemplatesService' => [], + 'google.dataflow.v1beta3.FlexTemplatesService' => [ + 'LaunchFlexTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\LaunchFlexTemplateResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + ], ], ]; diff --git a/Dataflow/src/V1beta3/resources/jobs_v1_beta3_descriptor_config.php b/Dataflow/src/V1beta3/resources/jobs_v1_beta3_descriptor_config.php index 9a769cbe5af9..72fac5975de0 100644 --- a/Dataflow/src/V1beta3/resources/jobs_v1_beta3_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/jobs_v1_beta3_descriptor_config.php @@ -12,6 +12,62 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getJobs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\ListJobsResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + ], + ], + 'CheckActiveJobs' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\CheckActiveJobsResponse', + ], + 'CreateJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Job', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'GetJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Job', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], ], 'ListJobs' => [ 'pageStreaming' => [ @@ -22,6 +78,70 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getJobs', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\ListJobsResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'SnapshotJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Snapshot', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'UpdateJob' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Job', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], ], ], ], diff --git a/Dataflow/src/V1beta3/resources/messages_v1_beta3_descriptor_config.php b/Dataflow/src/V1beta3/resources/messages_v1_beta3_descriptor_config.php index 83655ac1e9ac..92e76f70edec 100644 --- a/Dataflow/src/V1beta3/resources/messages_v1_beta3_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/messages_v1_beta3_descriptor_config.php @@ -12,6 +12,28 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getJobMessages', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\ListJobMessagesResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], ], ], ], diff --git a/Dataflow/src/V1beta3/resources/metrics_v1_beta3_descriptor_config.php b/Dataflow/src/V1beta3/resources/metrics_v1_beta3_descriptor_config.php index c125d09fbee0..298c38d58a43 100644 --- a/Dataflow/src/V1beta3/resources/metrics_v1_beta3_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/metrics_v1_beta3_descriptor_config.php @@ -12,6 +12,52 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getStages', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\JobExecutionDetails', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + ], + ], + 'GetJobMetrics' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\JobMetrics', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], ], 'GetStageExecutionDetails' => [ 'pageStreaming' => [ @@ -22,6 +68,34 @@ 'responsePageTokenGetMethod' => 'getNextPageToken', 'resourcesGetMethod' => 'getWorkers', ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\StageExecutionDetails', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + [ + 'keyName' => 'stage_id', + 'fieldAccessors' => [ + 'getStageId', + ], + ], + ], ], ], ], diff --git a/Dataflow/src/V1beta3/resources/snapshots_v1_beta3_descriptor_config.php b/Dataflow/src/V1beta3/resources/snapshots_v1_beta3_descriptor_config.php index 2f6341e70739..997e29031e3e 100644 --- a/Dataflow/src/V1beta3/resources/snapshots_v1_beta3_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/snapshots_v1_beta3_descriptor_config.php @@ -2,6 +2,79 @@ return [ 'interfaces' => [ - 'google.dataflow.v1beta3.SnapshotsV1Beta3' => [], + 'google.dataflow.v1beta3.SnapshotsV1Beta3' => [ + 'DeleteSnapshot' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\DeleteSnapshotResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + [ + 'keyName' => 'snapshot_id', + 'fieldAccessors' => [ + 'getSnapshotId', + ], + ], + ], + ], + 'GetSnapshot' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Snapshot', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'snapshot_id', + 'fieldAccessors' => [ + 'getSnapshotId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'ListSnapshots' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\ListSnapshotsResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + [ + 'keyName' => 'job_id', + 'fieldAccessors' => [ + 'getJobId', + ], + ], + ], + ], + ], ], ]; diff --git a/Dataflow/src/V1beta3/resources/templates_service_descriptor_config.php b/Dataflow/src/V1beta3/resources/templates_service_descriptor_config.php index 730778f71818..f826b2612275 100644 --- a/Dataflow/src/V1beta3/resources/templates_service_descriptor_config.php +++ b/Dataflow/src/V1beta3/resources/templates_service_descriptor_config.php @@ -2,6 +2,61 @@ return [ 'interfaces' => [ - 'google.dataflow.v1beta3.TemplatesService' => [], + 'google.dataflow.v1beta3.TemplatesService' => [ + 'CreateJobFromTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\Job', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'GetTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\GetTemplateResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + 'LaunchTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Dataflow\V1beta3\LaunchTemplateResponse', + 'headerParams' => [ + [ + 'keyName' => 'project_id', + 'fieldAccessors' => [ + 'getProjectId', + ], + ], + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getLocation', + ], + ], + ], + ], + ], ], ]; diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/FlexTemplatesServiceClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/FlexTemplatesServiceClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/FlexTemplatesServiceClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/FlexTemplatesServiceClientTest.php diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/JobsV1Beta3ClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/JobsV1Beta3ClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/JobsV1Beta3ClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/JobsV1Beta3ClientTest.php diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/MessagesV1Beta3ClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/MessagesV1Beta3ClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/MessagesV1Beta3ClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/MessagesV1Beta3ClientTest.php diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/MetricsV1Beta3ClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/MetricsV1Beta3ClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/MetricsV1Beta3ClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/MetricsV1Beta3ClientTest.php diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/SnapshotsV1Beta3ClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/SnapshotsV1Beta3ClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/SnapshotsV1Beta3ClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/SnapshotsV1Beta3ClientTest.php diff --git a/owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/TemplatesServiceClientTest.php b/Dataflow/tests/Unit/V1beta3/Client/TemplatesServiceClientTest.php similarity index 100% rename from owl-bot-staging/Dataflow/v1beta3/tests/Unit/V1beta3/Client/TemplatesServiceClientTest.php rename to Dataflow/tests/Unit/V1beta3/Client/TemplatesServiceClientTest.php diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Apikeys.php b/owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Apikeys.php deleted file mode 100644 index cfa4e162a3e1..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Apikeys.php +++ /dev/null @@ -1,85 +0,0 @@ -internalAddGeneratedFile( - ' -œ -#google/api/apikeys/v2/apikeys.protogoogle.api.apikeys.v2%google/api/apikeys/v2/resources.protogoogle/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.proto#google/longrunning/operations.proto google/protobuf/field_mask.proto"„ -CreateKeyRequest2 -parent ( B"àAúAapikeys.googleapis.com/Key, -key ( 2.google.api.apikeys.v2.KeyBàA -key_id ( "‘ -ListKeysRequest2 -parent ( B"àAúAapikeys.googleapis.com/Key - page_size (BàA - -page_token ( BàA - show_deleted (BàA"U -ListKeysResponse( -keys ( 2.google.api.apikeys.v2.Key -next_page_token ( "A - GetKeyRequest0 -name ( B"àAúA -apikeys.googleapis.com/Key"G -GetKeyStringRequest0 -name ( B"àAúA -apikeys.googleapis.com/Key"* -GetKeyStringResponse - -key_string ( "q -UpdateKeyRequest, -key ( 2.google.api.apikeys.v2.KeyBàA/ - update_mask ( 2.google.protobuf.FieldMask"W -DeleteKeyRequest0 -name ( B"àAúA -apikeys.googleapis.com/Key -etag ( BàA"F -UndeleteKeyRequest0 -name ( B"àAúA -apikeys.googleapis.com/Key"+ -LookupKeyRequest - -key_string ( BàA"1 -LookupKeyResponse -parent (  -name ( 2¾ -ApiKeys½ - CreateKey\'.google.api.apikeys.v2.CreateKeyRequest.google.longrunning.Operation"h‚Óä“/"(/v2/{parent=projects/*/locations/*}/keys:keyÚAparent,key,key_idÊA -Keygoogle.protobuf.Empty– -ListKeys&.google.api.apikeys.v2.ListKeysRequest\'.google.api.apikeys.v2.ListKeysResponse"9‚Óä“*(/v2/{parent=projects/*/locations/*}/keysÚAparentƒ -GetKey$.google.api.apikeys.v2.GetKeyRequest.google.api.apikeys.v2.Key"7‚Óä“*(/v2/{name=projects/*/locations/*/keys/*}ÚAnameª - GetKeyString*.google.api.apikeys.v2.GetKeyStringRequest+.google.api.apikeys.v2.GetKeyStringResponse"A‚Óä“42/v2/{name=projects/*/locations/*/keys/*}/keyStringÚAname¿ - UpdateKey\'.google.api.apikeys.v2.UpdateKeyRequest.google.longrunning.Operation"j‚Óä“32,/v2/{key.name=projects/*/locations/*/keys/*}:keyÚAkey,update_maskÊA -Keygoogle.protobuf.Empty« - DeleteKey\'.google.api.apikeys.v2.DeleteKeyRequest.google.longrunning.Operation"V‚Óä“**(/v2/{name=projects/*/locations/*/keys/*}ÚAnameÊA -Keygoogle.protobuf.Empty´ - UndeleteKey).google.api.apikeys.v2.UndeleteKeyRequest.google.longrunning.Operation"[‚Óä“6"1/v2/{name=projects/*/locations/*/keys/*}:undelete:*ÊA -Keygoogle.protobuf.Emptyz - LookupKey\'.google.api.apikeys.v2.LookupKeyRequest(.google.api.apikeys.v2.LookupKeyResponse"‚Óä“/v2/keys:lookupKeyƒÊAapikeys.googleapis.comÒAghttps://www.googleapis.com/auth/cloud-platform,https://www.googleapis.com/auth/cloud-platform.read-onlyB³ -com.google.api.apikeys.v2B ApiKeysProtoPZ5cloud.google.com/go/apikeys/apiv2/apikeyspb;apikeyspbªGoogle.Cloud.ApiKeys.V2ÊGoogle\\Cloud\\ApiKeys\\V2êGoogle::Cloud::ApiKeys::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Resources.php b/owl-bot-staging/ApiKeys/v2/proto/src/GPBMetadata/Google/Api/Apikeys/V2/Resources.php deleted file mode 100644 index 2647d4ef6503924ad540a7a875c8039914fc87dd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2368 zcma)8-EJF26vlSikmCU9HfbE+Ft|l^AYH?jO0Xe-P1-c7AfZILKr5{A?${Z!*;&oZ zrV5c?g$pjZ=OuUwu6xN7aAyDP$hH(qYmfJw@60*hd}n69{x&{~;UPI-5tCH2fDEpP zK4T=7LJMDnWRMJpOcGyQ#5`ouCS?DJ{CIRip6?%?e1uRX66rISjD#44tV3gNo^y7k zI+spIvdpgRG$KGmFPMs{&&a`X?+2!7KsEIaQn1&Jxp@rOJ9Tye{E#X|UKc^&8VG*k zWDs(nC`~o~JmRX)Bd$3O`R`c49vRY5F+|V$4wJ~&TtvhGjv}A6w@DV$_&$mSR=h`w zbdC)PNPu@3X(l5YdizZIlE+%eV{~=h5z{4g=1qG$pVoxqL(Q1uc^c>RAG}D<&gyux-maV9eW#a-w!#9 z^bO8iPvOCQVy!K>N5fFOVF4oWAd^fg)Kaaz(%ONIx!hUzF}EDUTV1DeopTOWj$-N*=5`LA3V4ntf|EU`?IT&-+8%U6_noe+rA|r6$kZ8;s4vi^JP$GlRKqYINP)=(?xQ;BLC}K7CvsLp#|~Jauv} OJhfBL>}(yw7~p^WTK_o! diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidApplication.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidApplication.php deleted file mode 100644 index 74f3d2346b24..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidApplication.php +++ /dev/null @@ -1,113 +0,0 @@ -google.api.apikeys.v2.AndroidApplication - */ -class AndroidApplication extends \Google\Protobuf\Internal\Message -{ - /** - * The SHA1 fingerprint of the application. For example, both sha1 formats are - * acceptable : DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09 or - * DA39A3EE5E6B4B0D3255BFEF95601890AFD80709. - * Output format is the latter. - * - * Generated from protobuf field string sha1_fingerprint = 1; - */ - protected $sha1_fingerprint = ''; - /** - * The package name of the application. - * - * Generated from protobuf field string package_name = 2; - */ - protected $package_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $sha1_fingerprint - * The SHA1 fingerprint of the application. For example, both sha1 formats are - * acceptable : DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09 or - * DA39A3EE5E6B4B0D3255BFEF95601890AFD80709. - * Output format is the latter. - * @type string $package_name - * The package name of the application. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The SHA1 fingerprint of the application. For example, both sha1 formats are - * acceptable : DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09 or - * DA39A3EE5E6B4B0D3255BFEF95601890AFD80709. - * Output format is the latter. - * - * Generated from protobuf field string sha1_fingerprint = 1; - * @return string - */ - public function getSha1Fingerprint() - { - return $this->sha1_fingerprint; - } - - /** - * The SHA1 fingerprint of the application. For example, both sha1 formats are - * acceptable : DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09 or - * DA39A3EE5E6B4B0D3255BFEF95601890AFD80709. - * Output format is the latter. - * - * Generated from protobuf field string sha1_fingerprint = 1; - * @param string $var - * @return $this - */ - public function setSha1Fingerprint($var) - { - GPBUtil::checkString($var, True); - $this->sha1_fingerprint = $var; - - return $this; - } - - /** - * The package name of the application. - * - * Generated from protobuf field string package_name = 2; - * @return string - */ - public function getPackageName() - { - return $this->package_name; - } - - /** - * The package name of the application. - * - * Generated from protobuf field string package_name = 2; - * @param string $var - * @return $this - */ - public function setPackageName($var) - { - GPBUtil::checkString($var, True); - $this->package_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidKeyRestrictions.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidKeyRestrictions.php deleted file mode 100644 index c0dfc3845aa6..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/AndroidKeyRestrictions.php +++ /dev/null @@ -1,71 +0,0 @@ -google.api.apikeys.v2.AndroidKeyRestrictions - */ -class AndroidKeyRestrictions extends \Google\Protobuf\Internal\Message -{ - /** - * A list of Android applications that are allowed to make API calls with - * this key. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.AndroidApplication allowed_applications = 1; - */ - private $allowed_applications; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApiKeys\V2\AndroidApplication>|\Google\Protobuf\Internal\RepeatedField $allowed_applications - * A list of Android applications that are allowed to make API calls with - * this key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * A list of Android applications that are allowed to make API calls with - * this key. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.AndroidApplication allowed_applications = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedApplications() - { - return $this->allowed_applications; - } - - /** - * A list of Android applications that are allowed to make API calls with - * this key. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.AndroidApplication allowed_applications = 1; - * @param array<\Google\Cloud\ApiKeys\V2\AndroidApplication>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedApplications($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApiKeys\V2\AndroidApplication::class); - $this->allowed_applications = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiKeysGrpcClient.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiKeysGrpcClient.php deleted file mode 100644 index b21215aa2c53..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiKeysGrpcClient.php +++ /dev/null @@ -1,184 +0,0 @@ -_simpleRequest('/google.api.apikeys.v2.ApiKeys/CreateKey', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists the API keys owned by a project. The key string of the API key - * isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\ListKeysRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListKeys(\Google\Cloud\ApiKeys\V2\ListKeysRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/ListKeys', - $argument, - ['\Google\Cloud\ApiKeys\V2\ListKeysResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the metadata for an API key. The key string of the API key - * isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\GetKeyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetKey(\Google\Cloud\ApiKeys\V2\GetKeyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/GetKey', - $argument, - ['\Google\Cloud\ApiKeys\V2\Key', 'decode'], - $metadata, $options); - } - - /** - * Get the key string for an API key. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\GetKeyStringRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetKeyString(\Google\Cloud\ApiKeys\V2\GetKeyStringRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/GetKeyString', - $argument, - ['\Google\Cloud\ApiKeys\V2\GetKeyStringResponse', 'decode'], - $metadata, $options); - } - - /** - * Patches the modifiable fields of an API key. - * The key string of the API key isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\UpdateKeyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateKey(\Google\Cloud\ApiKeys\V2\UpdateKeyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/UpdateKey', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes an API key. Deleted key can be retrieved within 30 days of - * deletion. Afterward, key will be purged from the project. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\DeleteKeyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteKey(\Google\Cloud\ApiKeys\V2\DeleteKeyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/DeleteKey', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Undeletes an API key which was deleted within 30 days. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @param \Google\Cloud\ApiKeys\V2\UndeleteKeyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UndeleteKey(\Google\Cloud\ApiKeys\V2\UndeleteKeyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/UndeleteKey', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Find the parent project and resource name of the API - * key that matches the key string in the request. If the API key has been - * purged, resource name will not be set. - * The service account must have the `apikeys.keys.lookup` permission - * on the parent project. - * @param \Google\Cloud\ApiKeys\V2\LookupKeyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function LookupKey(\Google\Cloud\ApiKeys\V2\LookupKeyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.api.apikeys.v2.ApiKeys/LookupKey', - $argument, - ['\Google\Cloud\ApiKeys\V2\LookupKeyResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiTarget.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiTarget.php deleted file mode 100644 index 196fb73d1918..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ApiTarget.php +++ /dev/null @@ -1,142 +0,0 @@ -google.api.apikeys.v2.ApiTarget - */ -class ApiTarget extends \Google\Protobuf\Internal\Message -{ - /** - * The service for this restriction. It should be the canonical - * service name, for example: `translate.googleapis.com`. - * You can use [`gcloud services list`](/sdk/gcloud/reference/services/list) - * to get a list of services that are enabled in the project. - * - * Generated from protobuf field string service = 1; - */ - protected $service = ''; - /** - * Optional. List of one or more methods that can be called. - * If empty, all methods for the service are allowed. A wildcard - * (*) can be used as the last symbol. - * Valid examples: - * `google.cloud.translate.v2.TranslateService.GetSupportedLanguage` - * `TranslateText` - * `Get*` - * `translate.googleapis.com.Get*` - * - * Generated from protobuf field repeated string methods = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $methods; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service - * The service for this restriction. It should be the canonical - * service name, for example: `translate.googleapis.com`. - * You can use [`gcloud services list`](/sdk/gcloud/reference/services/list) - * to get a list of services that are enabled in the project. - * @type array|\Google\Protobuf\Internal\RepeatedField $methods - * Optional. List of one or more methods that can be called. - * If empty, all methods for the service are allowed. A wildcard - * (*) can be used as the last symbol. - * Valid examples: - * `google.cloud.translate.v2.TranslateService.GetSupportedLanguage` - * `TranslateText` - * `Get*` - * `translate.googleapis.com.Get*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The service for this restriction. It should be the canonical - * service name, for example: `translate.googleapis.com`. - * You can use [`gcloud services list`](/sdk/gcloud/reference/services/list) - * to get a list of services that are enabled in the project. - * - * Generated from protobuf field string service = 1; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * The service for this restriction. It should be the canonical - * service name, for example: `translate.googleapis.com`. - * You can use [`gcloud services list`](/sdk/gcloud/reference/services/list) - * to get a list of services that are enabled in the project. - * - * Generated from protobuf field string service = 1; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * Optional. List of one or more methods that can be called. - * If empty, all methods for the service are allowed. A wildcard - * (*) can be used as the last symbol. - * Valid examples: - * `google.cloud.translate.v2.TranslateService.GetSupportedLanguage` - * `TranslateText` - * `Get*` - * `translate.googleapis.com.Get*` - * - * Generated from protobuf field repeated string methods = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMethods() - { - return $this->methods; - } - - /** - * Optional. List of one or more methods that can be called. - * If empty, all methods for the service are allowed. A wildcard - * (*) can be used as the last symbol. - * Valid examples: - * `google.cloud.translate.v2.TranslateService.GetSupportedLanguage` - * `TranslateText` - * `Get*` - * `translate.googleapis.com.Get*` - * - * Generated from protobuf field repeated string methods = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMethods($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->methods = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/BrowserKeyRestrictions.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/BrowserKeyRestrictions.php deleted file mode 100644 index d1562680d92f..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/BrowserKeyRestrictions.php +++ /dev/null @@ -1,71 +0,0 @@ -google.api.apikeys.v2.BrowserKeyRestrictions - */ -class BrowserKeyRestrictions extends \Google\Protobuf\Internal\Message -{ - /** - * A list of regular expressions for the referrer URLs that are allowed - * to make API calls with this key. - * - * Generated from protobuf field repeated string allowed_referrers = 1; - */ - private $allowed_referrers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $allowed_referrers - * A list of regular expressions for the referrer URLs that are allowed - * to make API calls with this key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * A list of regular expressions for the referrer URLs that are allowed - * to make API calls with this key. - * - * Generated from protobuf field repeated string allowed_referrers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedReferrers() - { - return $this->allowed_referrers; - } - - /** - * A list of regular expressions for the referrer URLs that are allowed - * to make API calls with this key. - * - * Generated from protobuf field repeated string allowed_referrers = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedReferrers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allowed_referrers = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/CreateKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/CreateKeyRequest.php deleted file mode 100644 index 9919979b799d..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/CreateKeyRequest.php +++ /dev/null @@ -1,205 +0,0 @@ -google.api.apikeys.v2.CreateKeyRequest - */ -class CreateKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project in which the API key is created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key = null; - /** - * User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * The id must NOT be a UUID-like string. - * - * Generated from protobuf field string key_id = 3; - */ - protected $key_id = ''; - - /** - * @param string $parent Required. The project in which the API key is created. Please see - * {@see ApiKeysClient::locationName()} for help formatting this field. - * @param \Google\Cloud\ApiKeys\V2\Key $key Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * @param string $keyId User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * - * The id must NOT be a UUID-like string. - * - * @return \Google\Cloud\ApiKeys\V2\CreateKeyRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApiKeys\V2\Key $key, string $keyId): self - { - return (new self()) - ->setParent($parent) - ->setKey($key) - ->setKeyId($keyId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project in which the API key is created. - * @type \Google\Cloud\ApiKeys\V2\Key $key - * Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * @type string $key_id - * User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * The id must NOT be a UUID-like string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project in which the API key is created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project in which the API key is created. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApiKeys\V2\Key|null - */ - public function getKey() - { - return $this->key; - } - - public function hasKey() - { - return isset($this->key); - } - - public function clearKey() - { - unset($this->key); - } - - /** - * Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApiKeys\V2\Key $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\Key::class); - $this->key = $var; - - return $this; - } - - /** - * User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * The id must NOT be a UUID-like string. - * - * Generated from protobuf field string key_id = 3; - * @return string - */ - public function getKeyId() - { - return $this->key_id; - } - - /** - * User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * The id must NOT be a UUID-like string. - * - * Generated from protobuf field string key_id = 3; - * @param string $var - * @return $this - */ - public function setKeyId($var) - { - GPBUtil::checkString($var, True); - $this->key_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/DeleteKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/DeleteKeyRequest.php deleted file mode 100644 index 203c84e8a5c6..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/DeleteKeyRequest.php +++ /dev/null @@ -1,119 +0,0 @@ -google.api.apikeys.v2.DeleteKeyRequest - */ -class DeleteKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the API key to be deleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. The etag known to the client for the expected state of the key. - * This is to be used for optimistic concurrency. - * - * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $etag = ''; - - /** - * @param string $name Required. The resource name of the API key to be deleted. Please see - * {@see ApiKeysClient::keyName()} for help formatting this field. - * - * @return \Google\Cloud\ApiKeys\V2\DeleteKeyRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the API key to be deleted. - * @type string $etag - * Optional. The etag known to the client for the expected state of the key. - * This is to be used for optimistic concurrency. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the API key to be deleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the API key to be deleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The etag known to the client for the expected state of the key. - * This is to be used for optimistic concurrency. - * - * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Optional. The etag known to the client for the expected state of the key. - * This is to be used for optimistic concurrency. - * - * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyRequest.php deleted file mode 100644 index e062f1a91d1b..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.api.apikeys.v2.GetKeyRequest - */ -class GetKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the API key to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the API key to get. Please see - * {@see ApiKeysClient::keyName()} for help formatting this field. - * - * @return \Google\Cloud\ApiKeys\V2\GetKeyRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the API key to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the API key to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the API key to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringRequest.php deleted file mode 100644 index fbaa776ed03d..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.api.apikeys.v2.GetKeyStringRequest - */ -class GetKeyStringRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the API key to be retrieved. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the API key to be retrieved. Please see - * {@see ApiKeysClient::keyName()} for help formatting this field. - * - * @return \Google\Cloud\ApiKeys\V2\GetKeyStringRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the API key to be retrieved. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the API key to be retrieved. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the API key to be retrieved. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringResponse.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringResponse.php deleted file mode 100644 index e54c1d58be2c..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/GetKeyStringResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.api.apikeys.v2.GetKeyStringResponse - */ -class GetKeyStringResponse extends \Google\Protobuf\Internal\Message -{ - /** - * An encrypted and signed value of the key. - * - * Generated from protobuf field string key_string = 1; - */ - protected $key_string = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_string - * An encrypted and signed value of the key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * An encrypted and signed value of the key. - * - * Generated from protobuf field string key_string = 1; - * @return string - */ - public function getKeyString() - { - return $this->key_string; - } - - /** - * An encrypted and signed value of the key. - * - * Generated from protobuf field string key_string = 1; - * @param string $var - * @return $this - */ - public function setKeyString($var) - { - GPBUtil::checkString($var, True); - $this->key_string = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/IosKeyRestrictions.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/IosKeyRestrictions.php deleted file mode 100644 index cdd2b259f381..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/IosKeyRestrictions.php +++ /dev/null @@ -1,67 +0,0 @@ -google.api.apikeys.v2.IosKeyRestrictions - */ -class IosKeyRestrictions extends \Google\Protobuf\Internal\Message -{ - /** - * A list of bundle IDs that are allowed when making API calls with this key. - * - * Generated from protobuf field repeated string allowed_bundle_ids = 1; - */ - private $allowed_bundle_ids; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $allowed_bundle_ids - * A list of bundle IDs that are allowed when making API calls with this key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * A list of bundle IDs that are allowed when making API calls with this key. - * - * Generated from protobuf field repeated string allowed_bundle_ids = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedBundleIds() - { - return $this->allowed_bundle_ids; - } - - /** - * A list of bundle IDs that are allowed when making API calls with this key. - * - * Generated from protobuf field repeated string allowed_bundle_ids = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedBundleIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allowed_bundle_ids = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Key.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Key.php deleted file mode 100644 index f88546c4dd1e..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Key.php +++ /dev/null @@ -1,477 +0,0 @@ -google.api.apikeys.v2.Key - */ -class Key extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the key. - * The `name` has the form: - * `projects//locations/global/keys/`. - * For example: - * `projects/123456867718/locations/global/keys/b7ff1f9f-8275-410a-94dd-3855ee9b5dd2` - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Unique id in UUID4 format. - * - * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Human-readable display name of this key that you can modify. - * The maximum length is 63 characters. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * Output only. An encrypted and signed value held by this key. - * This field can be accessed only through the `GetKeyString` method. - * - * Generated from protobuf field string key_string = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $key_string = ''; - /** - * Output only. A timestamp identifying the time this key was originally - * created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. A timestamp identifying the time this key was last - * updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. A timestamp when this key was deleted. If the resource is not deleted, - * this must be empty. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Annotations is an unstructured key-value map stored with a policy that - * may be set by external tools to store and retrieve arbitrary metadata. - * They are not queryable and should be preserved when modifying objects. - * - * Generated from protobuf field map annotations = 8; - */ - private $annotations; - /** - * Key restrictions. - * - * Generated from protobuf field .google.api.apikeys.v2.Restrictions restrictions = 9; - */ - protected $restrictions = null; - /** - * Output only. A checksum computed by the server based on the current value of the Key - * resource. This may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * See https://google.aip.dev/154. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $etag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the key. - * The `name` has the form: - * `projects//locations/global/keys/`. - * For example: - * `projects/123456867718/locations/global/keys/b7ff1f9f-8275-410a-94dd-3855ee9b5dd2` - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * @type string $uid - * Output only. Unique id in UUID4 format. - * @type string $display_name - * Human-readable display name of this key that you can modify. - * The maximum length is 63 characters. - * @type string $key_string - * Output only. An encrypted and signed value held by this key. - * This field can be accessed only through the `GetKeyString` method. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. A timestamp identifying the time this key was originally - * created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. A timestamp identifying the time this key was last - * updated. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. A timestamp when this key was deleted. If the resource is not deleted, - * this must be empty. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Annotations is an unstructured key-value map stored with a policy that - * may be set by external tools to store and retrieve arbitrary metadata. - * They are not queryable and should be preserved when modifying objects. - * @type \Google\Cloud\ApiKeys\V2\Restrictions $restrictions - * Key restrictions. - * @type string $etag - * Output only. A checksum computed by the server based on the current value of the Key - * resource. This may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * See https://google.aip.dev/154. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the key. - * The `name` has the form: - * `projects//locations/global/keys/`. - * For example: - * `projects/123456867718/locations/global/keys/b7ff1f9f-8275-410a-94dd-3855ee9b5dd2` - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the key. - * The `name` has the form: - * `projects//locations/global/keys/`. - * For example: - * `projects/123456867718/locations/global/keys/b7ff1f9f-8275-410a-94dd-3855ee9b5dd2` - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Unique id in UUID4 format. - * - * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. Unique id in UUID4 format. - * - * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Human-readable display name of this key that you can modify. - * The maximum length is 63 characters. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-readable display name of this key that you can modify. - * The maximum length is 63 characters. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. An encrypted and signed value held by this key. - * This field can be accessed only through the `GetKeyString` method. - * - * Generated from protobuf field string key_string = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getKeyString() - { - return $this->key_string; - } - - /** - * Output only. An encrypted and signed value held by this key. - * This field can be accessed only through the `GetKeyString` method. - * - * Generated from protobuf field string key_string = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setKeyString($var) - { - GPBUtil::checkString($var, True); - $this->key_string = $var; - - return $this; - } - - /** - * Output only. A timestamp identifying the time this key was originally - * created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. A timestamp identifying the time this key was originally - * created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. A timestamp identifying the time this key was last - * updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. A timestamp identifying the time this key was last - * updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. A timestamp when this key was deleted. If the resource is not deleted, - * this must be empty. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getDeleteTime() - { - return $this->delete_time; - } - - public function hasDeleteTime() - { - return isset($this->delete_time); - } - - public function clearDeleteTime() - { - unset($this->delete_time); - } - - /** - * Output only. A timestamp when this key was deleted. If the resource is not deleted, - * this must be empty. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setDeleteTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->delete_time = $var; - - return $this; - } - - /** - * Annotations is an unstructured key-value map stored with a policy that - * may be set by external tools to store and retrieve arbitrary metadata. - * They are not queryable and should be preserved when modifying objects. - * - * Generated from protobuf field map annotations = 8; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Annotations is an unstructured key-value map stored with a policy that - * may be set by external tools to store and retrieve arbitrary metadata. - * They are not queryable and should be preserved when modifying objects. - * - * Generated from protobuf field map annotations = 8; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - - /** - * Key restrictions. - * - * Generated from protobuf field .google.api.apikeys.v2.Restrictions restrictions = 9; - * @return \Google\Cloud\ApiKeys\V2\Restrictions|null - */ - public function getRestrictions() - { - return $this->restrictions; - } - - public function hasRestrictions() - { - return isset($this->restrictions); - } - - public function clearRestrictions() - { - unset($this->restrictions); - } - - /** - * Key restrictions. - * - * Generated from protobuf field .google.api.apikeys.v2.Restrictions restrictions = 9; - * @param \Google\Cloud\ApiKeys\V2\Restrictions $var - * @return $this - */ - public function setRestrictions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\Restrictions::class); - $this->restrictions = $var; - - return $this; - } - - /** - * Output only. A checksum computed by the server based on the current value of the Key - * resource. This may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * See https://google.aip.dev/154. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Output only. A checksum computed by the server based on the current value of the Key - * resource. This may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * See https://google.aip.dev/154. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysRequest.php deleted file mode 100644 index 04454c325db2..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysRequest.php +++ /dev/null @@ -1,187 +0,0 @@ -google.api.apikeys.v2.ListKeysRequest - */ -class ListKeysRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Lists all API keys associated with this project. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Specifies the maximum number of results to be returned at a time. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Requests a specific page of results. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Indicate that keys deleted in the past 30 days should also be - * returned. - * - * Generated from protobuf field bool show_deleted = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $show_deleted = false; - - /** - * @param string $parent Required. Lists all API keys associated with this project. Please see - * {@see ApiKeysClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\ApiKeys\V2\ListKeysRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Lists all API keys associated with this project. - * @type int $page_size - * Optional. Specifies the maximum number of results to be returned at a time. - * @type string $page_token - * Optional. Requests a specific page of results. - * @type bool $show_deleted - * Optional. Indicate that keys deleted in the past 30 days should also be - * returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. Lists all API keys associated with this project. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Lists all API keys associated with this project. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Specifies the maximum number of results to be returned at a time. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. Specifies the maximum number of results to be returned at a time. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. Requests a specific page of results. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Requests a specific page of results. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. Indicate that keys deleted in the past 30 days should also be - * returned. - * - * Generated from protobuf field bool show_deleted = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getShowDeleted() - { - return $this->show_deleted; - } - - /** - * Optional. Indicate that keys deleted in the past 30 days should also be - * returned. - * - * Generated from protobuf field bool show_deleted = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setShowDeleted($var) - { - GPBUtil::checkBool($var); - $this->show_deleted = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysResponse.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysResponse.php deleted file mode 100644 index e4bbd0c0d464..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ListKeysResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.api.apikeys.v2.ListKeysResponse - */ -class ListKeysResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of API keys. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.Key keys = 1; - */ - private $keys; - /** - * The pagination token for the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApiKeys\V2\Key>|\Google\Protobuf\Internal\RepeatedField $keys - * A list of API keys. - * @type string $next_page_token - * The pagination token for the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * A list of API keys. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.Key keys = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getKeys() - { - return $this->keys; - } - - /** - * A list of API keys. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.Key keys = 1; - * @param array<\Google\Cloud\ApiKeys\V2\Key>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setKeys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApiKeys\V2\Key::class); - $this->keys = $arr; - - return $this; - } - - /** - * The pagination token for the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The pagination token for the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyRequest.php deleted file mode 100644 index 4a9246dee323..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyRequest.php +++ /dev/null @@ -1,67 +0,0 @@ -google.api.apikeys.v2.LookupKeyRequest - */ -class LookupKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Finds the project that owns the key string value. - * - * Generated from protobuf field string key_string = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key_string = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_string - * Required. Finds the project that owns the key string value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. Finds the project that owns the key string value. - * - * Generated from protobuf field string key_string = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getKeyString() - { - return $this->key_string; - } - - /** - * Required. Finds the project that owns the key string value. - * - * Generated from protobuf field string key_string = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setKeyString($var) - { - GPBUtil::checkString($var, True); - $this->key_string = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyResponse.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyResponse.php deleted file mode 100644 index be7d242b0d07..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/LookupKeyResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.api.apikeys.v2.LookupKeyResponse - */ -class LookupKeyResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The project that owns the key with the value specified in the request. - * - * Generated from protobuf field string parent = 1; - */ - protected $parent = ''; - /** - * The resource name of the API key. If the API key has been purged, - * resource name is empty. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The project that owns the key with the value specified in the request. - * @type string $name - * The resource name of the API key. If the API key has been purged, - * resource name is empty. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * The project that owns the key with the value specified in the request. - * - * Generated from protobuf field string parent = 1; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The project that owns the key with the value specified in the request. - * - * Generated from protobuf field string parent = 1; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The resource name of the API key. If the API key has been purged, - * resource name is empty. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource name of the API key. If the API key has been purged, - * resource name is empty. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Restrictions.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Restrictions.php deleted file mode 100644 index 97489f2de4ab..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/Restrictions.php +++ /dev/null @@ -1,220 +0,0 @@ -google.api.apikeys.v2.Restrictions - */ -class Restrictions extends \Google\Protobuf\Internal\Message -{ - /** - * A restriction for a specific service and optionally one or - * more specific methods. Requests are allowed if they - * match any of these restrictions. If no restrictions are - * specified, all targets are allowed. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.ApiTarget api_targets = 5; - */ - private $api_targets; - protected $client_restrictions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApiKeys\V2\BrowserKeyRestrictions $browser_key_restrictions - * The HTTP referrers (websites) that are allowed to use the key. - * @type \Google\Cloud\ApiKeys\V2\ServerKeyRestrictions $server_key_restrictions - * The IP addresses of callers that are allowed to use the key. - * @type \Google\Cloud\ApiKeys\V2\AndroidKeyRestrictions $android_key_restrictions - * The Android apps that are allowed to use the key. - * @type \Google\Cloud\ApiKeys\V2\IosKeyRestrictions $ios_key_restrictions - * The iOS apps that are allowed to use the key. - * @type array<\Google\Cloud\ApiKeys\V2\ApiTarget>|\Google\Protobuf\Internal\RepeatedField $api_targets - * A restriction for a specific service and optionally one or - * more specific methods. Requests are allowed if they - * match any of these restrictions. If no restrictions are - * specified, all targets are allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The HTTP referrers (websites) that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.BrowserKeyRestrictions browser_key_restrictions = 1; - * @return \Google\Cloud\ApiKeys\V2\BrowserKeyRestrictions|null - */ - public function getBrowserKeyRestrictions() - { - return $this->readOneof(1); - } - - public function hasBrowserKeyRestrictions() - { - return $this->hasOneof(1); - } - - /** - * The HTTP referrers (websites) that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.BrowserKeyRestrictions browser_key_restrictions = 1; - * @param \Google\Cloud\ApiKeys\V2\BrowserKeyRestrictions $var - * @return $this - */ - public function setBrowserKeyRestrictions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\BrowserKeyRestrictions::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The IP addresses of callers that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.ServerKeyRestrictions server_key_restrictions = 2; - * @return \Google\Cloud\ApiKeys\V2\ServerKeyRestrictions|null - */ - public function getServerKeyRestrictions() - { - return $this->readOneof(2); - } - - public function hasServerKeyRestrictions() - { - return $this->hasOneof(2); - } - - /** - * The IP addresses of callers that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.ServerKeyRestrictions server_key_restrictions = 2; - * @param \Google\Cloud\ApiKeys\V2\ServerKeyRestrictions $var - * @return $this - */ - public function setServerKeyRestrictions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\ServerKeyRestrictions::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The Android apps that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.AndroidKeyRestrictions android_key_restrictions = 3; - * @return \Google\Cloud\ApiKeys\V2\AndroidKeyRestrictions|null - */ - public function getAndroidKeyRestrictions() - { - return $this->readOneof(3); - } - - public function hasAndroidKeyRestrictions() - { - return $this->hasOneof(3); - } - - /** - * The Android apps that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.AndroidKeyRestrictions android_key_restrictions = 3; - * @param \Google\Cloud\ApiKeys\V2\AndroidKeyRestrictions $var - * @return $this - */ - public function setAndroidKeyRestrictions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\AndroidKeyRestrictions::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * The iOS apps that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.IosKeyRestrictions ios_key_restrictions = 4; - * @return \Google\Cloud\ApiKeys\V2\IosKeyRestrictions|null - */ - public function getIosKeyRestrictions() - { - return $this->readOneof(4); - } - - public function hasIosKeyRestrictions() - { - return $this->hasOneof(4); - } - - /** - * The iOS apps that are allowed to use the key. - * - * Generated from protobuf field .google.api.apikeys.v2.IosKeyRestrictions ios_key_restrictions = 4; - * @param \Google\Cloud\ApiKeys\V2\IosKeyRestrictions $var - * @return $this - */ - public function setIosKeyRestrictions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\IosKeyRestrictions::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A restriction for a specific service and optionally one or - * more specific methods. Requests are allowed if they - * match any of these restrictions. If no restrictions are - * specified, all targets are allowed. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.ApiTarget api_targets = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiTargets() - { - return $this->api_targets; - } - - /** - * A restriction for a specific service and optionally one or - * more specific methods. Requests are allowed if they - * match any of these restrictions. If no restrictions are - * specified, all targets are allowed. - * - * Generated from protobuf field repeated .google.api.apikeys.v2.ApiTarget api_targets = 5; - * @param array<\Google\Cloud\ApiKeys\V2\ApiTarget>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiTargets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApiKeys\V2\ApiTarget::class); - $this->api_targets = $arr; - - return $this; - } - - /** - * @return string - */ - public function getClientRestrictions() - { - return $this->whichOneof("client_restrictions"); - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ServerKeyRestrictions.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ServerKeyRestrictions.php deleted file mode 100644 index c6ec92027b15..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/ServerKeyRestrictions.php +++ /dev/null @@ -1,71 +0,0 @@ -google.api.apikeys.v2.ServerKeyRestrictions - */ -class ServerKeyRestrictions extends \Google\Protobuf\Internal\Message -{ - /** - * A list of the caller IP addresses that are allowed to make API calls - * with this key. - * - * Generated from protobuf field repeated string allowed_ips = 1; - */ - private $allowed_ips; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $allowed_ips - * A list of the caller IP addresses that are allowed to make API calls - * with this key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Resources::initOnce(); - parent::__construct($data); - } - - /** - * A list of the caller IP addresses that are allowed to make API calls - * with this key. - * - * Generated from protobuf field repeated string allowed_ips = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedIps() - { - return $this->allowed_ips; - } - - /** - * A list of the caller IP addresses that are allowed to make API calls - * with this key. - * - * Generated from protobuf field repeated string allowed_ips = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedIps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allowed_ips = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UndeleteKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UndeleteKeyRequest.php deleted file mode 100644 index 4c3776147f8f..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UndeleteKeyRequest.php +++ /dev/null @@ -1,67 +0,0 @@ -google.api.apikeys.v2.UndeleteKeyRequest - */ -class UndeleteKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the API key to be undeleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the API key to be undeleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the API key to be undeleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the API key to be undeleted. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UpdateKeyRequest.php b/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UpdateKeyRequest.php deleted file mode 100644 index 4ea641ec88f3..000000000000 --- a/owl-bot-staging/ApiKeys/v2/proto/src/Google/Cloud/ApiKeys/V2/UpdateKeyRequest.php +++ /dev/null @@ -1,176 +0,0 @@ -google.api.apikeys.v2.UpdateKeyRequest - */ -class UpdateKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key = null; - /** - * The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\ApiKeys\V2\Key $key Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * @param \Google\Protobuf\FieldMask $updateMask The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * - * @return \Google\Cloud\ApiKeys\V2\UpdateKeyRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApiKeys\V2\Key $key, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setKey($key) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApiKeys\V2\Key $key - * Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * @type \Google\Protobuf\FieldMask $update_mask - * The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Apikeys\V2\Apikeys::initOnce(); - parent::__construct($data); - } - - /** - * Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApiKeys\V2\Key|null - */ - public function getKey() - { - return $this->key; - } - - public function hasKey() - { - return isset($this->key); - } - - public function clearKey() - { - unset($this->key); - } - - /** - * Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * - * Generated from protobuf field .google.api.apikeys.v2.Key key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApiKeys\V2\Key $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApiKeys\V2\Key::class); - $this->key = $var; - - return $this; - } - - /** - * The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/create_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/create_key.php deleted file mode 100644 index 45824f8a12cc..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/create_key.php +++ /dev/null @@ -1,88 +0,0 @@ -setParent($formattedParent) - ->setKey($key); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $apiKeysClient->createKey($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Key $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 = ApiKeysClient::locationName('[PROJECT]', '[LOCATION]'); - - create_key_sample($formattedParent); -} -// [END apikeys_v2_generated_ApiKeys_CreateKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/delete_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/delete_key.php deleted file mode 100644 index 93c0f7bb567a..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/delete_key.php +++ /dev/null @@ -1,87 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $apiKeysClient->deleteKey($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Key $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 = ApiKeysClient::keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - - delete_key_sample($formattedName); -} -// [END apikeys_v2_generated_ApiKeys_DeleteKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key.php deleted file mode 100644 index acbd19bb241a..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Key $response */ - $response = $apiKeysClient->getKey($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 = ApiKeysClient::keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - - get_key_sample($formattedName); -} -// [END apikeys_v2_generated_ApiKeys_GetKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key_string.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key_string.php deleted file mode 100644 index d6c744f1b9fb..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/get_key_string.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var GetKeyStringResponse $response */ - $response = $apiKeysClient->getKeyString($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 = ApiKeysClient::keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - - get_key_string_sample($formattedName); -} -// [END apikeys_v2_generated_ApiKeys_GetKeyString_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/list_keys.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/list_keys.php deleted file mode 100644 index 891227efb9b5..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/list_keys.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $apiKeysClient->listKeys($request); - - /** @var Key $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 = ApiKeysClient::locationName('[PROJECT]', '[LOCATION]'); - - list_keys_sample($formattedParent); -} -// [END apikeys_v2_generated_ApiKeys_ListKeys_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/lookup_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/lookup_key.php deleted file mode 100644 index 2b0726c0a7cc..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/lookup_key.php +++ /dev/null @@ -1,74 +0,0 @@ -setKeyString($keyString); - - // Call the API and handle any network failures. - try { - /** @var LookupKeyResponse $response */ - $response = $apiKeysClient->lookupKey($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 -{ - $keyString = '[KEY_STRING]'; - - lookup_key_sample($keyString); -} -// [END apikeys_v2_generated_ApiKeys_LookupKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/undelete_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/undelete_key.php deleted file mode 100644 index dc810a6ad4cf..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/undelete_key.php +++ /dev/null @@ -1,86 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $apiKeysClient->undeleteKey($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Key $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 = ApiKeysClient::keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - - undelete_key_sample($formattedName); -} -// [END apikeys_v2_generated_ApiKeys_UndeleteKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/update_key.php b/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/update_key.php deleted file mode 100644 index afea29e826ba..000000000000 --- a/owl-bot-staging/ApiKeys/v2/samples/V2/ApiKeysClient/update_key.php +++ /dev/null @@ -1,75 +0,0 @@ -setKey($key); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $apiKeysClient->updateKey($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Key $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 apikeys_v2_generated_ApiKeys_UpdateKey_sync] diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/ApiKeysClient.php b/owl-bot-staging/ApiKeys/v2/src/V2/ApiKeysClient.php deleted file mode 100644 index c4474ad434e5..000000000000 --- a/owl-bot-staging/ApiKeys/v2/src/V2/ApiKeysClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $key = new Key(); - * $operationResponse = $apiKeysClient->createKey($formattedParent, $key); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $apiKeysClient->createKey($formattedParent, $key); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $apiKeysClient->resumeOperation($operationName, 'createKey'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * 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. - */ -class ApiKeysGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.api.apikeys.v2.ApiKeys'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'apikeys.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - 'https://www.googleapis.com/auth/cloud-platform.read-only', - ]; - - private static $keyNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/api_keys_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/api_keys_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/api_keys_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/api_keys_rest_client_config.php', - ], - ], - ]; - } - - private static function getKeyNameTemplate() - { - if (self::$keyNameTemplate == null) { - self::$keyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/keys/{key}'); - } - - return self::$keyNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'key' => self::getKeyNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a key - * resource. - * - * @param string $project - * @param string $location - * @param string $key - * - * @return string The formatted key resource. - */ - public static function keyName($project, $location, $key) - { - return self::getKeyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'key' => $key, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - key: projects/{project}/locations/{location}/keys/{key} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'apikeys.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new API key. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedParent = $apiKeysClient->locationName('[PROJECT]', '[LOCATION]'); - * $key = new Key(); - * $operationResponse = $apiKeysClient->createKey($formattedParent, $key); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $apiKeysClient->createKey($formattedParent, $key); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $apiKeysClient->resumeOperation($operationName, 'createKey'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $parent Required. The project in which the API key is created. - * @param Key $key Required. The API key fields to set at creation time. - * You can configure only the `display_name`, `restrictions`, and - * `annotations` fields. - * @param array $optionalArgs { - * Optional. - * - * @type string $keyId - * User specified key id (optional). If specified, it will become the final - * component of the key resource name. - * - * The id must be unique within the project, must conform with RFC-1034, - * is restricted to lower-cased letters, and has a maximum length of 63 - * characters. In another word, the id must match the regular - * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. - * - * The id must NOT be a UUID-like string. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createKey($parent, $key, array $optionalArgs = []) - { - $request = new CreateKeyRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setKey($key); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['keyId'])) { - $request->setKeyId($optionalArgs['keyId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateKey', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes an API key. Deleted key can be retrieved within 30 days of - * deletion. Afterward, key will be purged from the project. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedName = $apiKeysClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - * $operationResponse = $apiKeysClient->deleteKey($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $apiKeysClient->deleteKey($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $apiKeysClient->resumeOperation($operationName, 'deleteKey'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the API key to be deleted. - * @param array $optionalArgs { - * Optional. - * - * @type string $etag - * Optional. The etag known to the client for the expected state of the key. - * This is to be used for optimistic concurrency. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteKey($name, array $optionalArgs = []) - { - $request = new DeleteKeyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['etag'])) { - $request->setEtag($optionalArgs['etag']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteKey', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets the metadata for an API key. The key string of the API key - * isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedName = $apiKeysClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - * $response = $apiKeysClient->getKey($formattedName); - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the API key to get. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApiKeys\V2\Key - * - * @throws ApiException if the remote call fails - */ - public function getKey($name, array $optionalArgs = []) - { - $request = new GetKeyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetKey', Key::class, $optionalArgs, $request)->wait(); - } - - /** - * Get the key string for an API key. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedName = $apiKeysClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - * $response = $apiKeysClient->getKeyString($formattedName); - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the API key to be retrieved. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApiKeys\V2\GetKeyStringResponse - * - * @throws ApiException if the remote call fails - */ - public function getKeyString($name, array $optionalArgs = []) - { - $request = new GetKeyStringRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetKeyString', GetKeyStringResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists the API keys owned by a project. The key string of the API key - * isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedParent = $apiKeysClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $apiKeysClient->listKeys($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $apiKeysClient->listKeys($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $parent Required. Lists all API keys associated with this project. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type bool $showDeleted - * Optional. Indicate that keys deleted in the past 30 days should also be - * returned. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listKeys($parent, array $optionalArgs = []) - { - $request = new ListKeysRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['showDeleted'])) { - $request->setShowDeleted($optionalArgs['showDeleted']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListKeys', $optionalArgs, ListKeysResponse::class, $request); - } - - /** - * Find the parent project and resource name of the API - * key that matches the key string in the request. If the API key has been - * purged, resource name will not be set. - * The service account must have the `apikeys.keys.lookup` permission - * on the parent project. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $keyString = 'key_string'; - * $response = $apiKeysClient->lookupKey($keyString); - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $keyString Required. Finds the project that owns the key string value. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApiKeys\V2\LookupKeyResponse - * - * @throws ApiException if the remote call fails - */ - public function lookupKey($keyString, array $optionalArgs = []) - { - $request = new LookupKeyRequest(); - $request->setKeyString($keyString); - return $this->startCall('LookupKey', LookupKeyResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Undeletes an API key which was deleted within 30 days. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $formattedName = $apiKeysClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - * $operationResponse = $apiKeysClient->undeleteKey($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $apiKeysClient->undeleteKey($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $apiKeysClient->resumeOperation($operationName, 'undeleteKey'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the API key to be undeleted. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function undeleteKey($name, array $optionalArgs = []) - { - $request = new UndeleteKeyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UndeleteKey', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Patches the modifiable fields of an API key. - * The key string of the API key isn't included in the response. - * - * NOTE: Key is a global resource; hence the only supported value for - * location is `global`. - * - * Sample code: - * ``` - * $apiKeysClient = new ApiKeysClient(); - * try { - * $key = new Key(); - * $operationResponse = $apiKeysClient->updateKey($key); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $apiKeysClient->updateKey($key); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $apiKeysClient->resumeOperation($operationName, 'updateKey'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $apiKeysClient->close(); - * } - * ``` - * - * @param Key $key Required. Set the `name` field to the resource name of the API key to be - * updated. You can update only the `display_name`, `restrictions`, and - * `annotations` fields. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The field mask specifies which fields to be updated as part of this - * request. All other fields are ignored. - * Mutable fields are: `display_name`, `restrictions`, and `annotations`. - * If an update mask is not provided, the service treats it as an implied mask - * equivalent to all allowed fields that are set on the wire. If the field - * mask has a special value "*", the service treats it equivalent to replace - * all allowed mutable fields. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateKey($key, array $optionalArgs = []) - { - $request = new UpdateKeyRequest(); - $requestParamHeaders = []; - $request->setKey($key); - $requestParamHeaders['key.name'] = $key->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateKey', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } -} diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/gapic_metadata.json b/owl-bot-staging/ApiKeys/v2/src/V2/gapic_metadata.json deleted file mode 100644 index 5054d5000712..000000000000 --- a/owl-bot-staging/ApiKeys/v2/src/V2/gapic_metadata.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.api.apikeys.v2", - "libraryPackage": "Google\\Cloud\\ApiKeys\\V2", - "services": { - "ApiKeys": { - "clients": { - "grpc": { - "libraryClient": "ApiKeysGapicClient", - "rpcs": { - "CreateKey": { - "methods": [ - "createKey" - ] - }, - "DeleteKey": { - "methods": [ - "deleteKey" - ] - }, - "GetKey": { - "methods": [ - "getKey" - ] - }, - "GetKeyString": { - "methods": [ - "getKeyString" - ] - }, - "ListKeys": { - "methods": [ - "listKeys" - ] - }, - "LookupKey": { - "methods": [ - "lookupKey" - ] - }, - "UndeleteKey": { - "methods": [ - "undeleteKey" - ] - }, - "UpdateKey": { - "methods": [ - "updateKey" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_client_config.json b/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_client_config.json deleted file mode 100644 index 08acf4cca498..000000000000 --- a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_client_config.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "interfaces": { - "google.api.apikeys.v2.ApiKeys": { - "retry_codes": { - "no_retry_codes": [], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 10000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 10000, - "total_timeout_millis": 10000 - } - }, - "methods": { - "CreateKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetKeyString": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListKeys": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "LookupKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UndeleteKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateKey": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_descriptor_config.php b/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_descriptor_config.php deleted file mode 100644 index cfdbad576236..000000000000 --- a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_descriptor_config.php +++ /dev/null @@ -1,137 +0,0 @@ - [ - 'google.api.apikeys.v2.ApiKeys' => [ - 'CreateKey' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ApiKeys\V2\Key', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteKey' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ApiKeys\V2\Key', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteKey' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ApiKeys\V2\Key', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateKey' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ApiKeys\V2\Key', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'key.name', - 'fieldAccessors' => [ - 'getKey', - 'getName', - ], - ], - ], - ], - 'GetKey' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApiKeys\V2\Key', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetKeyString' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApiKeys\V2\GetKeyStringResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListKeys' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getKeys', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApiKeys\V2\ListKeysResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'LookupKey' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApiKeys\V2\LookupKeyResponse', - ], - 'templateMap' => [ - 'key' => 'projects/{project}/locations/{location}/keys/{key}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_rest_client_config.php b/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_rest_client_config.php deleted file mode 100644 index 8a6b2ba0f2e9..000000000000 --- a/owl-bot-staging/ApiKeys/v2/src/V2/resources/api_keys_rest_client_config.php +++ /dev/null @@ -1,107 +0,0 @@ - [ - 'google.api.apikeys.v2.ApiKeys' => [ - 'CreateKey' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/keys', - 'body' => 'key', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteKey' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/keys/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetKey' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/keys/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetKeyString' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/keys/*}/keyString', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListKeys' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/keys', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'LookupKey' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/keys:lookupKey', - ], - 'UndeleteKey' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/keys/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateKey' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{key.name=projects/*/locations/*/keys/*}', - 'body' => 'key', - 'placeholders' => [ - 'key.name' => [ - 'getters' => [ - 'getKey', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/ApiKeys/v2/tests/Unit/V2/ApiKeysClientTest.php b/owl-bot-staging/ApiKeys/v2/tests/Unit/V2/ApiKeysClientTest.php deleted file mode 100644 index 6df3e267983a..000000000000 --- a/owl-bot-staging/ApiKeys/v2/tests/Unit/V2/ApiKeysClientTest.php +++ /dev/null @@ -1,838 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ApiKeysClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ApiKeysClient($options); - } - - /** @test */ - public function createKeyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $keyString = 'keyString526755313'; - $etag = 'etag3123477'; - $expectedResponse = new Key(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setKeyString($keyString); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createKeyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $key = new Key(); - $response = $gapicClient->createKey($formattedParent, $key); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/CreateKey', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getKey(); - $this->assertProtobufEquals($key, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createKeyTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createKeyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $key = new Key(); - $response = $gapicClient->createKey($formattedParent, $key); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createKeyTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteKeyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $keyString = 'keyString526755313'; - $etag2 = 'etag2-1293302904'; - $expectedResponse = new Key(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setKeyString($keyString); - $expectedResponse->setEtag($etag2); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteKeyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->deleteKey($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/DeleteKey', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteKeyTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteKeyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->deleteKey($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteKeyTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getKeyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $keyString = 'keyString526755313'; - $etag = 'etag3123477'; - $expectedResponse = new Key(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setKeyString($keyString); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->getKey($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/GetKey', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getKeyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - try { - $gapicClient->getKey($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getKeyStringTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $keyString = 'keyString526755313'; - $expectedResponse = new GetKeyStringResponse(); - $expectedResponse->setKeyString($keyString); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->getKeyString($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/GetKeyString', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getKeyStringExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - try { - $gapicClient->getKeyString($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listKeysTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $keysElement = new Key(); - $keys = [ - $keysElement, - ]; - $expectedResponse = new ListKeysResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setKeys($keys); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listKeys($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getKeys()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/ListKeys', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listKeysExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listKeys($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function lookupKeyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $parent = 'parent-995424086'; - $name = 'name3373707'; - $expectedResponse = new LookupKeyResponse(); - $expectedResponse->setParent($parent); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $keyString = 'keyString526755313'; - $response = $gapicClient->lookupKey($keyString); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/LookupKey', $actualFuncCall); - $actualValue = $actualRequestObject->getKeyString(); - $this->assertProtobufEquals($keyString, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function lookupKeyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $keyString = 'keyString526755313'; - try { - $gapicClient->lookupKey($keyString); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function undeleteKeyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/undeleteKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $keyString = 'keyString526755313'; - $etag = 'etag3123477'; - $expectedResponse = new Key(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setKeyString($keyString); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeleteKeyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->undeleteKey($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/UndeleteKey', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteKeyTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function undeleteKeyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/undeleteKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->keyName('[PROJECT]', '[LOCATION]', '[KEY]'); - $response = $gapicClient->undeleteKey($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteKeyTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateKeyTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $keyString = 'keyString526755313'; - $etag = 'etag3123477'; - $expectedResponse = new Key(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setKeyString($keyString); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateKeyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $key = new Key(); - $response = $gapicClient->updateKey($key); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.api.apikeys.v2.ApiKeys/UpdateKey', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getKey(); - $this->assertProtobufEquals($key, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateKeyTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateKeyExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $key = new Key(); - $response = $gapicClient->updateKey($key); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateKeyTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/GPBMetadata/Google/Cloud/Apigeeregistry/V1/ProvisioningService.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/GPBMetadata/Google/Cloud/Apigeeregistry/V1/ProvisioningService.php deleted file mode 100644 index e9e59fc38f4224f5602bbea91ca44c364505db85..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3297 zcmbtWOK;;;6eejKGB-ojG3pS4rnu>dNvqaY11##cjGRZSj7l5YvU~&!LX#SaN&N?P5?yKb*^#$*8gjK#Ys`YH?+iQ>YjV$V zdKOkq%NcZ3!zDe8J=`Nc^-k2IWfcIAh)*1w*u9pIy(3~`g?|Mh+vsE8HB2mT)=Qsb zYIF>0G&eb5v&;aS`Uqh2V0jfG(=vQtuE&7)1TH#7GW@xNwna?Yrv`<8Pl?|mHlf6@ z$TvWAUG5r|j{)bhZFgXs6k?T`!;Wp@!n`anne9{80b$nVFhYocI-patW>f6hhSjWK z-}Hz}9j^|in%2WKQkcCd%m<%kaHK02M2wntDadu1dIKE)x-5H`4m^96$ISqS(NpsZ z{Xn^Xh)IaYP*Ney+PXsHQsyx#ieBZ(y^k zYVNqKhVMr*%3Xs%4N{};UL7&d`O;@3$gtk&LW~U_X21*fqr8d5}lO$Fm}*oX=t^BJOl>s#|*qc?BHlFII_+aRh>xD3m@Q( z3nj18P&Q$Z|1p84%N~YNQnNu$Xq{dB^#GKWR#3_{Jcu=$kQ0RmrTIVg=?Yx6bk{$b>b;uTqOpO-$&CG zY~jn{uAy-@mV#gv9&7=9bRiiRA`Y?hyGYu^H2fJ#@c%IXNT5eiiHB2CQc=d_dbe0A zc(|EjE)*fmlMD9j8Q!)d(2B<wSq(#UJQd)L;H)}Us;!Y1|A)8J{Sh6LeV_&8KaFcRQp z_&6;7GJzh}V;h0=cLGh04kYQ*+Y}$Q54tz^By@{SNF{2>{P5e~|N1Vul3!xm&Z!u6 z>k*fQ7>9*e>{>LxUg;kQr^S#>^Z-NeOn(yVjw|NCufTJ3lHJa8)c%e<3FoOU2%fC8 zu3;HV(8BPQ&inaHUqI7hXo?F1?hvKgcj<|A1*h*5C=(l_QZdZHb-frf4%yuKKFF^L zV$vHC%Y6YEy76-OO;-*nb$v}$kB^T7CedAI4CtZQotIn~nq9~1m;OnhJlun~kS=B8 z^&V`%@QOP1#FsCGQi0;^Qtdexmve{#Dt0t>x4nAt#Sh7uO}>#UWwwzkI^W25gB4#n zSUw94n!(NinternalAddGeneratedFile( - ' -æ -4google/cloud/apigeeregistry/v1/registry_models.protogoogle.cloud.apigeeregistry.v1google/api/resource.protogoogle/protobuf/timestamp.proto"© -Api -name (  - display_name (  - description ( 4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA - availability ( J -recommended_version ( B-úA* -(apigeeregistry.googleapis.com/ApiVersionP -recommended_deployment ( B0úA- -+apigeeregistry.googleapis.com/ApiDeployment? -labels ( 2/.google.cloud.apigeeregistry.v1.Api.LabelsEntryI - annotations - ( 24.google.cloud.apigeeregistry.v1.Api.AnnotationsEntry- - LabelsEntry -key (  -value ( :82 -AnnotationsEntry -key (  -value ( :8:ZêAW -!apigeeregistry.googleapis.com/Api2projects/{project}/locations/{location}/apis/{api}"³ - -ApiVersion -name (  - display_name (  - description ( 4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA -state ( F -labels ( 26.google.cloud.apigeeregistry.v1.ApiVersion.LabelsEntryP - annotations ( 2;.google.cloud.apigeeregistry.v1.ApiVersion.AnnotationsEntry- - LabelsEntry -key (  -value ( :82 -AnnotationsEntry -key (  -value ( :8:têAq -(apigeeregistry.googleapis.com/ApiVersionEprojects/{project}/locations/{location}/apis/{api}/versions/{version}"ð -ApiSpec -name (  -filename (  - description (  - revision_id ( BàAàA4 - create_time ( 2.google.protobuf.TimestampBàA= -revision_create_time ( 2.google.protobuf.TimestampBàA= -revision_update_time ( 2.google.protobuf.TimestampBàA - mime_type (  - -size_bytes (BàA -hash - ( BàA - -source_uri (  -contents ( BàAC -labels ( 23.google.cloud.apigeeregistry.v1.ApiSpec.LabelsEntryM - annotations ( 28.google.cloud.apigeeregistry.v1.ApiSpec.AnnotationsEntry- - LabelsEntry -key (  -value ( :82 -AnnotationsEntry -key (  -value ( :8:~êA{ -%apigeeregistry.googleapis.com/ApiSpecRprojects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}"Ê - ApiDeployment -name (  - display_name (  - description (  - revision_id ( BàAàA4 - create_time ( 2.google.protobuf.TimestampBàA= -revision_create_time ( 2.google.protobuf.TimestampBàA= -revision_update_time ( 2.google.protobuf.TimestampBàAE -api_spec_revision ( B*úA\' -%apigeeregistry.googleapis.com/ApiSpec - endpoint_uri (  -external_channel_uri - (  -intended_audience (  -access_guidance ( I -labels ( 29.google.cloud.apigeeregistry.v1.ApiDeployment.LabelsEntryS - annotations ( 2>.google.cloud.apigeeregistry.v1.ApiDeployment.AnnotationsEntry- - LabelsEntry -key (  -value ( :82 -AnnotationsEntry -key (  -value ( :8:}êAz -+apigeeregistry.googleapis.com/ApiDeploymentKprojects/{project}/locations/{location}/apis/{api}/deployments/{deployment}"· -Artifact -name ( 4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA - mime_type (  - -size_bytes (BàA -hash ( BàA -contents ( BàA:ÚêAÖ -&apigeeregistry.googleapis.com/ArtifactinternalAddGeneratedFile( - ' -òr -5google/cloud/apigeeregistry/v1/registry_service.protogoogle.cloud.apigeeregistry.v1google/api/client.protogoogle/api/field_behavior.protogoogle/api/httpbody.protogoogle/api/resource.proto4google/cloud/apigeeregistry/v1/registry_models.protogoogle/protobuf/empty.proto google/protobuf/field_mask.proto"ƒ -ListApisRequest9 -parent ( B)àAúA#!apigeeregistry.googleapis.com/Api - page_size ( - -page_token (  -filter ( "^ -ListApisResponse1 -apis ( 2#.google.cloud.apigeeregistry.v1.Api -next_page_token ( "H - GetApiRequest7 -name ( B)àAúA# -!apigeeregistry.googleapis.com/Api"™ -CreateApiRequest9 -parent ( B)àAúA#!apigeeregistry.googleapis.com/Api5 -api ( 2#.google.cloud.apigeeregistry.v1.ApiBàA -api_id ( BàA"‘ -UpdateApiRequest5 -api ( 2#.google.cloud.apigeeregistry.v1.ApiBàA/ - update_mask ( 2.google.protobuf.FieldMask - allow_missing ("Z -DeleteApiRequest7 -name ( B)àAúA# -!apigeeregistry.googleapis.com/Api -force ("‘ -ListApiVersionsRequest@ -parent ( B0àAúA*(apigeeregistry.googleapis.com/ApiVersion - page_size ( - -page_token (  -filter ( "t -ListApiVersionsResponse@ - api_versions ( 2*.google.cloud.apigeeregistry.v1.ApiVersion -next_page_token ( "V -GetApiVersionRequest> -name ( B0àAúA* -(apigeeregistry.googleapis.com/ApiVersion"¾ -CreateApiVersionRequest@ -parent ( B0àAúA*(apigeeregistry.googleapis.com/ApiVersionD - api_version ( 2*.google.cloud.apigeeregistry.v1.ApiVersionBàA -api_version_id ( BàA"§ -UpdateApiVersionRequestD - api_version ( 2*.google.cloud.apigeeregistry.v1.ApiVersionBàA/ - update_mask ( 2.google.protobuf.FieldMask - allow_missing ("h -DeleteApiVersionRequest> -name ( B0àAúA* -(apigeeregistry.googleapis.com/ApiVersion -force ("‹ -ListApiSpecsRequest= -parent ( B-àAúA\'%apigeeregistry.googleapis.com/ApiSpec - page_size ( - -page_token (  -filter ( "k -ListApiSpecsResponse: - api_specs ( 2\'.google.cloud.apigeeregistry.v1.ApiSpec -next_page_token ( "P -GetApiSpecRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec"X -GetApiSpecContentsRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec"¯ -CreateApiSpecRequest= -parent ( B-àAúA\'%apigeeregistry.googleapis.com/ApiSpec> -api_spec ( 2\'.google.cloud.apigeeregistry.v1.ApiSpecBàA - api_spec_id ( BàA"ž -UpdateApiSpecRequest> -api_spec ( 2\'.google.cloud.apigeeregistry.v1.ApiSpecBàA/ - update_mask ( 2.google.protobuf.FieldMask - allow_missing ("b -DeleteApiSpecRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec -force ("j -TagApiSpecRevisionRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec -tag ( BàA" -ListApiSpecRevisionsRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec - page_size ( - -page_token ( "s -ListApiSpecRevisionsResponse: - api_specs ( 2\'.google.cloud.apigeeregistry.v1.ApiSpec -next_page_token ( "o -RollbackApiSpecRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec - revision_id ( BàA"[ -DeleteApiSpecRevisionRequest; -name ( B-àAúA\' -%apigeeregistry.googleapis.com/ApiSpec"— -ListApiDeploymentsRequestC -parent ( B3àAúA-+apigeeregistry.googleapis.com/ApiDeployment - page_size ( - -page_token (  -filter ( "} -ListApiDeploymentsResponseF -api_deployments ( 2-.google.cloud.apigeeregistry.v1.ApiDeployment -next_page_token ( "\\ -GetApiDeploymentRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment"Í -CreateApiDeploymentRequestC -parent ( B3àAúA-+apigeeregistry.googleapis.com/ApiDeploymentJ -api_deployment ( 2-.google.cloud.apigeeregistry.v1.ApiDeploymentBàA -api_deployment_id ( BàA"° -UpdateApiDeploymentRequestJ -api_deployment ( 2-.google.cloud.apigeeregistry.v1.ApiDeploymentBàA/ - update_mask ( 2.google.protobuf.FieldMask - allow_missing ("n -DeleteApiDeploymentRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment -force ("v -TagApiDeploymentRevisionRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment -tag ( BàA" -!ListApiDeploymentRevisionsRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment - page_size ( - -page_token ( "… -"ListApiDeploymentRevisionsResponseF -api_deployments ( 2-.google.cloud.apigeeregistry.v1.ApiDeployment -next_page_token ( "{ -RollbackApiDeploymentRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment - revision_id ( BàA"g -"DeleteApiDeploymentRevisionRequestA -name ( B3àAúA- -+apigeeregistry.googleapis.com/ApiDeployment" -ListArtifactsRequest> -parent ( B.àAúA(&apigeeregistry.googleapis.com/Artifact - page_size ( - -page_token (  -filter ( "m -ListArtifactsResponse; - artifacts ( 2(.google.cloud.apigeeregistry.v1.Artifact -next_page_token ( "R -GetArtifactRequest< -name ( B.àAúA( -&apigeeregistry.googleapis.com/Artifact"Z -GetArtifactContentsRequest< -name ( B.àAúA( -&apigeeregistry.googleapis.com/Artifact"² -CreateArtifactRequest> -parent ( B.àAúA(&apigeeregistry.googleapis.com/Artifact? -artifact ( 2(.google.cloud.apigeeregistry.v1.ArtifactBàA - artifact_id ( BàA"Y -ReplaceArtifactRequest? -artifact ( 2(.google.cloud.apigeeregistry.v1.ArtifactBàA"U -DeleteArtifactRequest< -name ( B.àAúA( -&apigeeregistry.googleapis.com/Artifact2ÀE -Registry¨ -ListApis/.google.cloud.apigeeregistry.v1.ListApisRequest0.google.cloud.apigeeregistry.v1.ListApisResponse"9‚Óä“*(/v1/{parent=projects/*/locations/*}/apisÚAparent• -GetApi-.google.cloud.apigeeregistry.v1.GetApiRequest#.google.cloud.apigeeregistry.v1.Api"7‚Óä“*(/v1/{name=projects/*/locations/*/apis/*}ÚAname­ - CreateApi0.google.cloud.apigeeregistry.v1.CreateApiRequest#.google.cloud.apigeeregistry.v1.Api"I‚Óä“/"(/v1/{parent=projects/*/locations/*}/apis:apiÚAparent,api,api_id¯ - UpdateApi0.google.cloud.apigeeregistry.v1.UpdateApiRequest#.google.cloud.apigeeregistry.v1.Api"K‚Óä“32,/v1/{api.name=projects/*/locations/*/apis/*}:apiÚAapi,update_maskŽ - DeleteApi0.google.cloud.apigeeregistry.v1.DeleteApiRequest.google.protobuf.Empty"7‚Óä“**(/v1/{name=projects/*/locations/*/apis/*}ÚAnameÈ -ListApiVersions6.google.cloud.apigeeregistry.v1.ListApiVersionsRequest7.google.cloud.apigeeregistry.v1.ListApiVersionsResponse"D‚Óä“53/v1/{parent=projects/*/locations/*/apis/*}/versionsÚAparentµ - GetApiVersion4.google.cloud.apigeeregistry.v1.GetApiVersionRequest*.google.cloud.apigeeregistry.v1.ApiVersion"B‚Óä“53/v1/{name=projects/*/locations/*/apis/*/versions/*}ÚAnameå -CreateApiVersion7.google.cloud.apigeeregistry.v1.CreateApiVersionRequest*.google.cloud.apigeeregistry.v1.ApiVersion"l‚Óä“B"3/v1/{parent=projects/*/locations/*/apis/*}/versions: api_versionÚA!parent,api_version,api_version_idç -UpdateApiVersion7.google.cloud.apigeeregistry.v1.UpdateApiVersionRequest*.google.cloud.apigeeregistry.v1.ApiVersion"n‚Óä“N2?/v1/{api_version.name=projects/*/locations/*/apis/*/versions/*}: api_versionÚAapi_version,update_mask§ -DeleteApiVersion7.google.cloud.apigeeregistry.v1.DeleteApiVersionRequest.google.protobuf.Empty"B‚Óä“5*3/v1/{name=projects/*/locations/*/apis/*/versions/*}ÚAnameÇ - ListApiSpecs3.google.cloud.apigeeregistry.v1.ListApiSpecsRequest4.google.cloud.apigeeregistry.v1.ListApiSpecsResponse"L‚Óä“=;/v1/{parent=projects/*/locations/*/apis/*/versions/*}/specsÚAparent´ - -GetApiSpec1.google.cloud.apigeeregistry.v1.GetApiSpecRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"J‚Óä“=;/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}ÚAname½ -GetApiSpecContents9.google.cloud.apigeeregistry.v1.GetApiSpecContentsRequest.google.api.HttpBody"V‚Óä“IG/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:getContentsÚAnameÛ - CreateApiSpec4.google.cloud.apigeeregistry.v1.CreateApiSpecRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"k‚Óä“G";/v1/{parent=projects/*/locations/*/apis/*/versions/*}/specs:api_specÚAparent,api_spec,api_spec_idÝ - UpdateApiSpec4.google.cloud.apigeeregistry.v1.UpdateApiSpecRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"m‚Óä“P2D/v1/{api_spec.name=projects/*/locations/*/apis/*/versions/*/specs/*}:api_specÚAapi_spec,update_mask© - DeleteApiSpec4.google.cloud.apigeeregistry.v1.DeleteApiSpecRequest.google.protobuf.Empty"J‚Óä“=*;/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}ÚAnameÌ -TagApiSpecRevision9.google.cloud.apigeeregistry.v1.TagApiSpecRevisionRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"R‚Óä“L"G/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:tagRevision:*ä -ListApiSpecRevisions;.google.cloud.apigeeregistry.v1.ListApiSpecRevisionsRequest<.google.cloud.apigeeregistry.v1.ListApiSpecRevisionsResponse"Q‚Óä“KI/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:listRevisionsà -RollbackApiSpec6.google.cloud.apigeeregistry.v1.RollbackApiSpecRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"O‚Óä“I"D/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:rollback:*Ù -DeleteApiSpecRevision<.google.cloud.apigeeregistry.v1.DeleteApiSpecRevisionRequest\'.google.cloud.apigeeregistry.v1.ApiSpec"Y‚Óä“L*J/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:deleteRevisionÚAnameÔ -ListApiDeployments9.google.cloud.apigeeregistry.v1.ListApiDeploymentsRequest:.google.cloud.apigeeregistry.v1.ListApiDeploymentsResponse"G‚Óä“86/v1/{parent=projects/*/locations/*/apis/*}/deploymentsÚAparentÁ -GetApiDeployment7.google.cloud.apigeeregistry.v1.GetApiDeploymentRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"E‚Óä“86/v1/{name=projects/*/locations/*/apis/*/deployments/*}ÚAnameú -CreateApiDeployment:.google.cloud.apigeeregistry.v1.CreateApiDeploymentRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"x‚Óä“H"6/v1/{parent=projects/*/locations/*/apis/*}/deployments:api_deploymentÚA\'parent,api_deployment,api_deployment_idü -UpdateApiDeployment:.google.cloud.apigeeregistry.v1.UpdateApiDeploymentRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"z‚Óä“W2E/v1/{api_deployment.name=projects/*/locations/*/apis/*/deployments/*}:api_deploymentÚAapi_deployment,update_mask° -DeleteApiDeployment:.google.cloud.apigeeregistry.v1.DeleteApiDeploymentRequest.google.protobuf.Empty"E‚Óä“8*6/v1/{name=projects/*/locations/*/apis/*/deployments/*}ÚAnameÙ -TagApiDeploymentRevision?.google.cloud.apigeeregistry.v1.TagApiDeploymentRevisionRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"M‚Óä“G"B/v1/{name=projects/*/locations/*/apis/*/deployments/*}:tagRevision:*ñ -ListApiDeploymentRevisionsA.google.cloud.apigeeregistry.v1.ListApiDeploymentRevisionsRequestB.google.cloud.apigeeregistry.v1.ListApiDeploymentRevisionsResponse"L‚Óä“FD/v1/{name=projects/*/locations/*/apis/*/deployments/*}:listRevisionsÐ -RollbackApiDeployment<.google.cloud.apigeeregistry.v1.RollbackApiDeploymentRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"J‚Óä“D"?/v1/{name=projects/*/locations/*/apis/*/deployments/*}:rollback:*æ -DeleteApiDeploymentRevisionB.google.cloud.apigeeregistry.v1.DeleteApiDeploymentRevisionRequest-.google.cloud.apigeeregistry.v1.ApiDeployment"T‚Óä“G*E/v1/{name=projects/*/locations/*/apis/*/deployments/*}:deleteRevisionÚAnameÊ - ListArtifacts4.google.cloud.apigeeregistry.v1.ListArtifactsRequest5.google.cloud.apigeeregistry.v1.ListArtifactsResponse"Ë‚Óä“»-/v1/{parent=projects/*/locations/*}/artifactsZ64/v1/{parent=projects/*/locations/*/apis/*}/artifactsZA?/v1/{parent=projects/*/locations/*/apis/*/versions/*}/artifactsZIG/v1/{parent=projects/*/locations/*/apis/*/versions/*/specs/*}/artifactsZDB/v1/{parent=projects/*/locations/*/apis/*/deployments/*}/artifactsÚAparent· - GetArtifact2.google.cloud.apigeeregistry.v1.GetArtifactRequest(.google.cloud.apigeeregistry.v1.Artifact"É‚Óä“»-/v1/{name=projects/*/locations/*/artifacts/*}Z64/v1/{name=projects/*/locations/*/apis/*/artifacts/*}ZA?/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}ZIG/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}ZDB/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}ÚAnameï -GetArtifactContents:.google.cloud.apigeeregistry.v1.GetArtifactContentsRequest.google.api.HttpBody"…‚Óä“÷9/v1/{name=projects/*/locations/*/artifacts/*}:getContentsZB@/v1/{name=projects/*/locations/*/apis/*/artifacts/*}:getContentsZMK/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}:getContentsZUS/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:getContentsZPN/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}:getContentsÚAname† -CreateArtifact5.google.cloud.apigeeregistry.v1.CreateArtifactRequest(.google.cloud.apigeeregistry.v1.Artifact"’‚Óä“í"-/v1/{parent=projects/*/locations/*}/artifacts:artifactZ@"4/v1/{parent=projects/*/locations/*/apis/*}/artifacts:artifactZK"?/v1/{parent=projects/*/locations/*/apis/*/versions/*}/artifacts:artifactZS"G/v1/{parent=projects/*/locations/*/apis/*/versions/*/specs/*}/artifacts:artifactZN"B/v1/{parent=projects/*/locations/*/apis/*/deployments/*}/artifacts:artifactÚAparent,artifact,artifact_id¢ -ReplaceArtifact6.google.cloud.apigeeregistry.v1.ReplaceArtifactRequest(.google.cloud.apigeeregistry.v1.Artifact"¬‚Óä“š6/v1/{artifact.name=projects/*/locations/*/artifacts/*}:artifactZI=/v1/{artifact.name=projects/*/locations/*/apis/*/artifacts/*}:artifactZTH/v1/{artifact.name=projects/*/locations/*/apis/*/versions/*/artifacts/*}:artifactZ\\P/v1/{artifact.name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:artifactZWK/v1/{artifact.name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}:artifactÚAartifact« -DeleteArtifact5.google.cloud.apigeeregistry.v1.DeleteArtifactRequest.google.protobuf.Empty"É‚Óä“»*-/v1/{name=projects/*/locations/*/artifacts/*}Z6*4/v1/{name=projects/*/locations/*/apis/*/artifacts/*}ZA*?/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}ZI*G/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}ZD*B/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}ÚAnameQÊAapigeeregistry.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformBî -"com.google.cloud.apigeeregistry.v1BRegistryServiceProtoPZJcloud.google.com/go/apigeeregistry/apiv1/apigeeregistrypb;apigeeregistrypbªGoogle.Cloud.ApigeeRegistry.V1ÊGoogle\\Cloud\\ApigeeRegistry\\V1ê!Google::Cloud::ApigeeRegistry::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Api.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Api.php deleted file mode 100644 index 493dcfe906ee..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Api.php +++ /dev/null @@ -1,458 +0,0 @@ -google.cloud.apigeeregistry.v1.Api - */ -class Api extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * A user-definable description of the availability of this service. - * Format: free-form, but we expect single words that describe availability, - * e.g., "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN". - * - * Generated from protobuf field string availability = 6; - */ - protected $availability = ''; - /** - * The recommended version of the API. - * Format: `apis/{api}/versions/{version}` - * - * Generated from protobuf field string recommended_version = 7 [(.google.api.resource_reference) = { - */ - protected $recommended_version = ''; - /** - * The recommended deployment of the API. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string recommended_deployment = 8 [(.google.api.resource_reference) = { - */ - protected $recommended_deployment = ''; - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores, and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 9; - */ - private $labels; - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 10; - */ - private $annotations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type string $display_name - * Human-meaningful name. - * @type string $description - * A detailed description. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update timestamp. - * @type string $availability - * A user-definable description of the availability of this service. - * Format: free-form, but we expect single words that describe availability, - * e.g., "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN". - * @type string $recommended_version - * The recommended version of the API. - * Format: `apis/{api}/versions/{version}` - * @type string $recommended_deployment - * The recommended deployment of the API. - * Format: `apis/{api}/deployments/{deployment}` - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores, and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryModels::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * A user-definable description of the availability of this service. - * Format: free-form, but we expect single words that describe availability, - * e.g., "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN". - * - * Generated from protobuf field string availability = 6; - * @return string - */ - public function getAvailability() - { - return $this->availability; - } - - /** - * A user-definable description of the availability of this service. - * Format: free-form, but we expect single words that describe availability, - * e.g., "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN". - * - * Generated from protobuf field string availability = 6; - * @param string $var - * @return $this - */ - public function setAvailability($var) - { - GPBUtil::checkString($var, True); - $this->availability = $var; - - return $this; - } - - /** - * The recommended version of the API. - * Format: `apis/{api}/versions/{version}` - * - * Generated from protobuf field string recommended_version = 7 [(.google.api.resource_reference) = { - * @return string - */ - public function getRecommendedVersion() - { - return $this->recommended_version; - } - - /** - * The recommended version of the API. - * Format: `apis/{api}/versions/{version}` - * - * Generated from protobuf field string recommended_version = 7 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRecommendedVersion($var) - { - GPBUtil::checkString($var, True); - $this->recommended_version = $var; - - return $this; - } - - /** - * The recommended deployment of the API. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string recommended_deployment = 8 [(.google.api.resource_reference) = { - * @return string - */ - public function getRecommendedDeployment() - { - return $this->recommended_deployment; - } - - /** - * The recommended deployment of the API. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string recommended_deployment = 8 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRecommendedDeployment($var) - { - GPBUtil::checkString($var, True); - $this->recommended_deployment = $var; - - return $this; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores, and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 9; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores, and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 9; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 10; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 10; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiDeployment.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiDeployment.php deleted file mode 100644 index 8633b657fe3d..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiDeployment.php +++ /dev/null @@ -1,623 +0,0 @@ -google.cloud.apigeeregistry.v1.ApiDeployment - */ -class ApiDeployment extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. Immutable. The revision ID of the deployment. - * A new revision is committed whenever the deployment contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_id = ''; - /** - * Output only. Creation timestamp; when the deployment resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_create_time = null; - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_update_time = null; - /** - * The full resource name (including revision ID) of the spec of the API being - * served by the deployment. Changes to this value will update the revision. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string api_spec_revision = 8 [(.google.api.resource_reference) = { - */ - protected $api_spec_revision = ''; - /** - * The address where the deployment is serving. Changes to this value will - * update the revision. - * - * Generated from protobuf field string endpoint_uri = 9; - */ - protected $endpoint_uri = ''; - /** - * The address of the external channel of the API (e.g., the Developer - * Portal). Changes to this value will not affect the revision. - * - * Generated from protobuf field string external_channel_uri = 10; - */ - protected $external_channel_uri = ''; - /** - * Text briefly identifying the intended audience of the API. Changes to this - * value will not affect the revision. - * - * Generated from protobuf field string intended_audience = 11; - */ - protected $intended_audience = ''; - /** - * Text briefly describing how to access the endpoint. Changes to this value - * will not affect the revision. - * - * Generated from protobuf field string access_guidance = 12; - */ - protected $access_guidance = ''; - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - */ - private $labels; - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - */ - private $annotations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type string $display_name - * Human-meaningful name. - * @type string $description - * A detailed description. - * @type string $revision_id - * Output only. Immutable. The revision ID of the deployment. - * A new revision is committed whenever the deployment contents are changed. - * The format is an 8-character hexadecimal string. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp; when the deployment resource was created. - * @type \Google\Protobuf\Timestamp $revision_create_time - * Output only. Revision creation timestamp; when the represented revision was created. - * @type \Google\Protobuf\Timestamp $revision_update_time - * Output only. Last update timestamp: when the represented revision was last modified. - * @type string $api_spec_revision - * The full resource name (including revision ID) of the spec of the API being - * served by the deployment. Changes to this value will update the revision. - * Format: `apis/{api}/deployments/{deployment}` - * @type string $endpoint_uri - * The address where the deployment is serving. Changes to this value will - * update the revision. - * @type string $external_channel_uri - * The address of the external channel of the API (e.g., the Developer - * Portal). Changes to this value will not affect the revision. - * @type string $intended_audience - * Text briefly identifying the intended audience of the API. Changes to this - * value will not affect the revision. - * @type string $access_guidance - * Text briefly describing how to access the endpoint. Changes to this value - * will not affect the revision. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryModels::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. Immutable. The revision ID of the deployment. - * A new revision is committed whenever the deployment contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Output only. Immutable. The revision ID of the deployment. - * A new revision is committed whenever the deployment contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - - /** - * Output only. Creation timestamp; when the deployment resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp; when the deployment resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRevisionCreateTime() - { - return $this->revision_create_time; - } - - public function hasRevisionCreateTime() - { - return isset($this->revision_create_time); - } - - public function clearRevisionCreateTime() - { - unset($this->revision_create_time); - } - - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRevisionCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->revision_create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRevisionUpdateTime() - { - return $this->revision_update_time; - } - - public function hasRevisionUpdateTime() - { - return isset($this->revision_update_time); - } - - public function clearRevisionUpdateTime() - { - unset($this->revision_update_time); - } - - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRevisionUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->revision_update_time = $var; - - return $this; - } - - /** - * The full resource name (including revision ID) of the spec of the API being - * served by the deployment. Changes to this value will update the revision. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string api_spec_revision = 8 [(.google.api.resource_reference) = { - * @return string - */ - public function getApiSpecRevision() - { - return $this->api_spec_revision; - } - - /** - * The full resource name (including revision ID) of the spec of the API being - * served by the deployment. Changes to this value will update the revision. - * Format: `apis/{api}/deployments/{deployment}` - * - * Generated from protobuf field string api_spec_revision = 8 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setApiSpecRevision($var) - { - GPBUtil::checkString($var, True); - $this->api_spec_revision = $var; - - return $this; - } - - /** - * The address where the deployment is serving. Changes to this value will - * update the revision. - * - * Generated from protobuf field string endpoint_uri = 9; - * @return string - */ - public function getEndpointUri() - { - return $this->endpoint_uri; - } - - /** - * The address where the deployment is serving. Changes to this value will - * update the revision. - * - * Generated from protobuf field string endpoint_uri = 9; - * @param string $var - * @return $this - */ - public function setEndpointUri($var) - { - GPBUtil::checkString($var, True); - $this->endpoint_uri = $var; - - return $this; - } - - /** - * The address of the external channel of the API (e.g., the Developer - * Portal). Changes to this value will not affect the revision. - * - * Generated from protobuf field string external_channel_uri = 10; - * @return string - */ - public function getExternalChannelUri() - { - return $this->external_channel_uri; - } - - /** - * The address of the external channel of the API (e.g., the Developer - * Portal). Changes to this value will not affect the revision. - * - * Generated from protobuf field string external_channel_uri = 10; - * @param string $var - * @return $this - */ - public function setExternalChannelUri($var) - { - GPBUtil::checkString($var, True); - $this->external_channel_uri = $var; - - return $this; - } - - /** - * Text briefly identifying the intended audience of the API. Changes to this - * value will not affect the revision. - * - * Generated from protobuf field string intended_audience = 11; - * @return string - */ - public function getIntendedAudience() - { - return $this->intended_audience; - } - - /** - * Text briefly identifying the intended audience of the API. Changes to this - * value will not affect the revision. - * - * Generated from protobuf field string intended_audience = 11; - * @param string $var - * @return $this - */ - public function setIntendedAudience($var) - { - GPBUtil::checkString($var, True); - $this->intended_audience = $var; - - return $this; - } - - /** - * Text briefly describing how to access the endpoint. Changes to this value - * will not affect the revision. - * - * Generated from protobuf field string access_guidance = 12; - * @return string - */ - public function getAccessGuidance() - { - return $this->access_guidance; - } - - /** - * Text briefly describing how to access the endpoint. Changes to this value - * will not affect the revision. - * - * Generated from protobuf field string access_guidance = 12; - * @param string $var - * @return $this - */ - public function setAccessGuidance($var) - { - GPBUtil::checkString($var, True); - $this->access_guidance = $var; - - return $this; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiSpec.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiSpec.php deleted file mode 100644 index 7b1714abd03a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiSpec.php +++ /dev/null @@ -1,658 +0,0 @@ -google.cloud.apigeeregistry.v1.ApiSpec - */ -class ApiSpec extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A possibly-hierarchical name used to refer to the spec from other specs. - * - * Generated from protobuf field string filename = 2; - */ - protected $filename = ''; - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. Immutable. The revision ID of the spec. - * A new revision is committed whenever the spec contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_id = ''; - /** - * Output only. Creation timestamp; when the spec resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_create_time = null; - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_update_time = null; - /** - * A style (format) descriptor for this spec that is specified as a Media Type - * (https://en.wikipedia.org/wiki/Media_type). Possible values include - * `application/vnd.apigee.proto`, `application/vnd.apigee.openapi`, and - * `application/vnd.apigee.graphql`, with possible suffixes representing - * compression types. These hypothetical names are defined in the vendor tree - * defined in RFC6838 (https://tools.ietf.org/html/rfc6838) and are not final. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 8; - */ - protected $mime_type = ''; - /** - * Output only. The size of the spec file in bytes. If the spec is gzipped, this is the - * size of the uncompressed spec. - * - * Generated from protobuf field int32 size_bytes = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $size_bytes = 0; - /** - * Output only. A SHA-256 hash of the spec's contents. If the spec is gzipped, this is - * the hash of the uncompressed spec. - * - * Generated from protobuf field string hash = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $hash = ''; - /** - * The original source URI of the spec (if one exists). - * This is an external location that can be used for reference purposes - * but which may not be authoritative since this external resource may - * change after the spec is retrieved. - * - * Generated from protobuf field string source_uri = 11; - */ - protected $source_uri = ''; - /** - * Input only. The contents of the spec. - * Provided by API callers when specs are created or updated. - * To access the contents of a spec, use GetApiSpecContents. - * - * Generated from protobuf field bytes contents = 12 [(.google.api.field_behavior) = INPUT_ONLY]; - */ - protected $contents = ''; - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - */ - private $labels; - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - */ - private $annotations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type string $filename - * A possibly-hierarchical name used to refer to the spec from other specs. - * @type string $description - * A detailed description. - * @type string $revision_id - * Output only. Immutable. The revision ID of the spec. - * A new revision is committed whenever the spec contents are changed. - * The format is an 8-character hexadecimal string. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp; when the spec resource was created. - * @type \Google\Protobuf\Timestamp $revision_create_time - * Output only. Revision creation timestamp; when the represented revision was created. - * @type \Google\Protobuf\Timestamp $revision_update_time - * Output only. Last update timestamp: when the represented revision was last modified. - * @type string $mime_type - * A style (format) descriptor for this spec that is specified as a Media Type - * (https://en.wikipedia.org/wiki/Media_type). Possible values include - * `application/vnd.apigee.proto`, `application/vnd.apigee.openapi`, and - * `application/vnd.apigee.graphql`, with possible suffixes representing - * compression types. These hypothetical names are defined in the vendor tree - * defined in RFC6838 (https://tools.ietf.org/html/rfc6838) and are not final. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * @type int $size_bytes - * Output only. The size of the spec file in bytes. If the spec is gzipped, this is the - * size of the uncompressed spec. - * @type string $hash - * Output only. A SHA-256 hash of the spec's contents. If the spec is gzipped, this is - * the hash of the uncompressed spec. - * @type string $source_uri - * The original source URI of the spec (if one exists). - * This is an external location that can be used for reference purposes - * but which may not be authoritative since this external resource may - * change after the spec is retrieved. - * @type string $contents - * Input only. The contents of the spec. - * Provided by API callers when specs are created or updated. - * To access the contents of a spec, use GetApiSpecContents. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryModels::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A possibly-hierarchical name used to refer to the spec from other specs. - * - * Generated from protobuf field string filename = 2; - * @return string - */ - public function getFilename() - { - return $this->filename; - } - - /** - * A possibly-hierarchical name used to refer to the spec from other specs. - * - * Generated from protobuf field string filename = 2; - * @param string $var - * @return $this - */ - public function setFilename($var) - { - GPBUtil::checkString($var, True); - $this->filename = $var; - - return $this; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. Immutable. The revision ID of the spec. - * A new revision is committed whenever the spec contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Output only. Immutable. The revision ID of the spec. - * A new revision is committed whenever the spec contents are changed. - * The format is an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 4 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - - /** - * Output only. Creation timestamp; when the spec resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp; when the spec resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRevisionCreateTime() - { - return $this->revision_create_time; - } - - public function hasRevisionCreateTime() - { - return isset($this->revision_create_time); - } - - public function clearRevisionCreateTime() - { - unset($this->revision_create_time); - } - - /** - * Output only. Revision creation timestamp; when the represented revision was created. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRevisionCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->revision_create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRevisionUpdateTime() - { - return $this->revision_update_time; - } - - public function hasRevisionUpdateTime() - { - return isset($this->revision_update_time); - } - - public function clearRevisionUpdateTime() - { - unset($this->revision_update_time); - } - - /** - * Output only. Last update timestamp: when the represented revision was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp revision_update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRevisionUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->revision_update_time = $var; - - return $this; - } - - /** - * A style (format) descriptor for this spec that is specified as a Media Type - * (https://en.wikipedia.org/wiki/Media_type). Possible values include - * `application/vnd.apigee.proto`, `application/vnd.apigee.openapi`, and - * `application/vnd.apigee.graphql`, with possible suffixes representing - * compression types. These hypothetical names are defined in the vendor tree - * defined in RFC6838 (https://tools.ietf.org/html/rfc6838) and are not final. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 8; - * @return string - */ - public function getMimeType() - { - return $this->mime_type; - } - - /** - * A style (format) descriptor for this spec that is specified as a Media Type - * (https://en.wikipedia.org/wiki/Media_type). Possible values include - * `application/vnd.apigee.proto`, `application/vnd.apigee.openapi`, and - * `application/vnd.apigee.graphql`, with possible suffixes representing - * compression types. These hypothetical names are defined in the vendor tree - * defined in RFC6838 (https://tools.ietf.org/html/rfc6838) and are not final. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 8; - * @param string $var - * @return $this - */ - public function setMimeType($var) - { - GPBUtil::checkString($var, True); - $this->mime_type = $var; - - return $this; - } - - /** - * Output only. The size of the spec file in bytes. If the spec is gzipped, this is the - * size of the uncompressed spec. - * - * Generated from protobuf field int32 size_bytes = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getSizeBytes() - { - return $this->size_bytes; - } - - /** - * Output only. The size of the spec file in bytes. If the spec is gzipped, this is the - * size of the uncompressed spec. - * - * Generated from protobuf field int32 size_bytes = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setSizeBytes($var) - { - GPBUtil::checkInt32($var); - $this->size_bytes = $var; - - return $this; - } - - /** - * Output only. A SHA-256 hash of the spec's contents. If the spec is gzipped, this is - * the hash of the uncompressed spec. - * - * Generated from protobuf field string hash = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getHash() - { - return $this->hash; - } - - /** - * Output only. A SHA-256 hash of the spec's contents. If the spec is gzipped, this is - * the hash of the uncompressed spec. - * - * Generated from protobuf field string hash = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setHash($var) - { - GPBUtil::checkString($var, True); - $this->hash = $var; - - return $this; - } - - /** - * The original source URI of the spec (if one exists). - * This is an external location that can be used for reference purposes - * but which may not be authoritative since this external resource may - * change after the spec is retrieved. - * - * Generated from protobuf field string source_uri = 11; - * @return string - */ - public function getSourceUri() - { - return $this->source_uri; - } - - /** - * The original source URI of the spec (if one exists). - * This is an external location that can be used for reference purposes - * but which may not be authoritative since this external resource may - * change after the spec is retrieved. - * - * Generated from protobuf field string source_uri = 11; - * @param string $var - * @return $this - */ - public function setSourceUri($var) - { - GPBUtil::checkString($var, True); - $this->source_uri = $var; - - return $this; - } - - /** - * Input only. The contents of the spec. - * Provided by API callers when specs are created or updated. - * To access the contents of a spec, use GetApiSpecContents. - * - * Generated from protobuf field bytes contents = 12 [(.google.api.field_behavior) = INPUT_ONLY]; - * @return string - */ - public function getContents() - { - return $this->contents; - } - - /** - * Input only. The contents of the spec. - * Provided by API callers when specs are created or updated. - * To access the contents of a spec, use GetApiSpecContents. - * - * Generated from protobuf field bytes contents = 12 [(.google.api.field_behavior) = INPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setContents($var) - { - GPBUtil::checkString($var, False); - $this->contents = $var; - - return $this; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 14; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 15; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiVersion.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiVersion.php deleted file mode 100644 index 9d9c76302da0..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ApiVersion.php +++ /dev/null @@ -1,386 +0,0 @@ -google.cloud.apigeeregistry.v1.ApiVersion - */ -class ApiVersion extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * A user-definable description of the lifecycle phase of this API version. - * Format: free-form, but we expect single words that describe API maturity, - * e.g., "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION", - * "DEPRECATED", "RETIRED". - * - * Generated from protobuf field string state = 6; - */ - protected $state = ''; - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 7; - */ - private $labels; - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 8; - */ - private $annotations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type string $display_name - * Human-meaningful name. - * @type string $description - * A detailed description. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update timestamp. - * @type string $state - * A user-definable description of the lifecycle phase of this API version. - * Format: free-form, but we expect single words that describe API maturity, - * e.g., "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION", - * "DEPRECATED", "RETIRED". - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryModels::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-meaningful name. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A detailed description. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * A user-definable description of the lifecycle phase of this API version. - * Format: free-form, but we expect single words that describe API maturity, - * e.g., "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION", - * "DEPRECATED", "RETIRED". - * - * Generated from protobuf field string state = 6; - * @return string - */ - public function getState() - { - return $this->state; - } - - /** - * A user-definable description of the lifecycle phase of this API version. - * Format: free-form, but we expect single words that describe API maturity, - * e.g., "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION", - * "DEPRECATED", "RETIRED". - * - * Generated from protobuf field string state = 6; - * @param string $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkString($var, True); - $this->state = $var; - - return $this; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels attach identifying metadata to resources. Identifying metadata can - * be used to filter list operations. - * Label keys and values can be no longer than 64 characters - * (Unicode codepoints), can only contain lowercase letters, numeric - * characters, underscores and dashes. International characters are allowed. - * No more than 64 user labels can be associated with one resource (System - * labels are excluded). - * See https://goo.gl/xmQnxf for more information and examples of labels. - * System reserved label keys are prefixed with - * `apigeeregistry.googleapis.com/` and cannot be changed. - * - * Generated from protobuf field map labels = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 8; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Annotations attach non-identifying metadata to resources. - * Annotation keys and values are less restricted than those of labels, but - * should be generally used for small values of broad interest. Larger, topic- - * specific metadata should be stored in Artifacts. - * - * Generated from protobuf field map annotations = 8; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Artifact.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Artifact.php deleted file mode 100644 index 81472f82caab..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Artifact.php +++ /dev/null @@ -1,334 +0,0 @@ -google.cloud.apigeeregistry.v1.Artifact - */ -class Artifact extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * A content type specifier for the artifact. - * Content type specifiers are Media Types - * (https://en.wikipedia.org/wiki/Media_type) with a possible "schema" - * parameter that specifies a schema for the stored information. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 4; - */ - protected $mime_type = ''; - /** - * Output only. The size of the artifact in bytes. If the artifact is gzipped, this is - * the size of the uncompressed artifact. - * - * Generated from protobuf field int32 size_bytes = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $size_bytes = 0; - /** - * Output only. A SHA-256 hash of the artifact's contents. If the artifact is gzipped, - * this is the hash of the uncompressed artifact. - * - * Generated from protobuf field string hash = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $hash = ''; - /** - * Input only. The contents of the artifact. - * Provided by API callers when artifacts are created or replaced. - * To access the contents of an artifact, use GetArtifactContents. - * - * Generated from protobuf field bytes contents = 7 [(.google.api.field_behavior) = INPUT_ONLY]; - */ - protected $contents = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update timestamp. - * @type string $mime_type - * A content type specifier for the artifact. - * Content type specifiers are Media Types - * (https://en.wikipedia.org/wiki/Media_type) with a possible "schema" - * parameter that specifies a schema for the stored information. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * @type int $size_bytes - * Output only. The size of the artifact in bytes. If the artifact is gzipped, this is - * the size of the uncompressed artifact. - * @type string $hash - * Output only. A SHA-256 hash of the artifact's contents. If the artifact is gzipped, - * this is the hash of the uncompressed artifact. - * @type string $contents - * Input only. The contents of the artifact. - * Provided by API callers when artifacts are created or replaced. - * To access the contents of an artifact, use GetArtifactContents. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryModels::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * A content type specifier for the artifact. - * Content type specifiers are Media Types - * (https://en.wikipedia.org/wiki/Media_type) with a possible "schema" - * parameter that specifies a schema for the stored information. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 4; - * @return string - */ - public function getMimeType() - { - return $this->mime_type; - } - - /** - * A content type specifier for the artifact. - * Content type specifiers are Media Types - * (https://en.wikipedia.org/wiki/Media_type) with a possible "schema" - * parameter that specifies a schema for the stored information. - * Content types can specify compression. Currently only GZip compression is - * supported (indicated with "+gzip"). - * - * Generated from protobuf field string mime_type = 4; - * @param string $var - * @return $this - */ - public function setMimeType($var) - { - GPBUtil::checkString($var, True); - $this->mime_type = $var; - - return $this; - } - - /** - * Output only. The size of the artifact in bytes. If the artifact is gzipped, this is - * the size of the uncompressed artifact. - * - * Generated from protobuf field int32 size_bytes = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getSizeBytes() - { - return $this->size_bytes; - } - - /** - * Output only. The size of the artifact in bytes. If the artifact is gzipped, this is - * the size of the uncompressed artifact. - * - * Generated from protobuf field int32 size_bytes = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setSizeBytes($var) - { - GPBUtil::checkInt32($var); - $this->size_bytes = $var; - - return $this; - } - - /** - * Output only. A SHA-256 hash of the artifact's contents. If the artifact is gzipped, - * this is the hash of the uncompressed artifact. - * - * Generated from protobuf field string hash = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getHash() - { - return $this->hash; - } - - /** - * Output only. A SHA-256 hash of the artifact's contents. If the artifact is gzipped, - * this is the hash of the uncompressed artifact. - * - * Generated from protobuf field string hash = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setHash($var) - { - GPBUtil::checkString($var, True); - $this->hash = $var; - - return $this; - } - - /** - * Input only. The contents of the artifact. - * Provided by API callers when artifacts are created or replaced. - * To access the contents of an artifact, use GetArtifactContents. - * - * Generated from protobuf field bytes contents = 7 [(.google.api.field_behavior) = INPUT_ONLY]; - * @return string - */ - public function getContents() - { - return $this->contents; - } - - /** - * Input only. The contents of the artifact. - * Provided by API callers when artifacts are created or replaced. - * To access the contents of an artifact, use GetArtifactContents. - * - * Generated from protobuf field bytes contents = 7 [(.google.api.field_behavior) = INPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setContents($var) - { - GPBUtil::checkString($var, False); - $this->contents = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiDeploymentRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiDeploymentRequest.php deleted file mode 100644 index 05a8fcd9c088..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiDeploymentRequest.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateApiDeploymentRequest - */ -class CreateApiDeploymentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The deployment to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_deployment = null; - /** - * Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_deployment_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_deployment_id = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment Required. The deployment to create. - * @param string $apiDeploymentId Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiDeploymentRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment, string $apiDeploymentId): self - { - return (new self()) - ->setParent($parent) - ->setApiDeployment($apiDeployment) - ->setApiDeploymentId($apiDeploymentId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * @type \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $api_deployment - * Required. The deployment to create. - * @type string $api_deployment_id - * Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The deployment to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment|null - */ - public function getApiDeployment() - { - return $this->api_deployment; - } - - public function hasApiDeployment() - { - return isset($this->api_deployment); - } - - public function clearApiDeployment() - { - unset($this->api_deployment); - } - - /** - * Required. The deployment to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $var - * @return $this - */ - public function setApiDeployment($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment::class); - $this->api_deployment = $var; - - return $this; - } - - /** - * Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_deployment_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getApiDeploymentId() - { - return $this->api_deployment_id; - } - - /** - * Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_deployment_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setApiDeploymentId($var) - { - GPBUtil::checkString($var, True); - $this->api_deployment_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiRequest.php deleted file mode 100644 index 817c624551a5..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiRequest.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateApiRequest - */ -class CreateApiRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The API to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api = null; - /** - * Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_id = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * Please see {@see RegistryClient::locationName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\Api $api Required. The API to create. - * @param string $apiId Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Api $api, string $apiId): self - { - return (new self()) - ->setParent($parent) - ->setApi($api) - ->setApiId($apiId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * @type \Google\Cloud\ApigeeRegistry\V1\Api $api - * Required. The API to create. - * @type string $api_id - * Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The API to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Api|null - */ - public function getApi() - { - return $this->api; - } - - public function hasApi() - { - return isset($this->api); - } - - public function clearApi() - { - unset($this->api); - } - - /** - * Required. The API to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Api $var - * @return $this - */ - public function setApi($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Api::class); - $this->api = $var; - - return $this; - } - - /** - * Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getApiId() - { - return $this->api_id; - } - - /** - * Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setApiId($var) - { - GPBUtil::checkString($var, True); - $this->api_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiSpecRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiSpecRequest.php deleted file mode 100644 index 871e03740f15..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiSpecRequest.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateApiSpecRequest - */ -class CreateApiSpecRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The spec to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_spec = null; - /** - * Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_spec_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_spec_id = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec Required. The spec to create. - * @param string $apiSpecId Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiSpecRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec, string $apiSpecId): self - { - return (new self()) - ->setParent($parent) - ->setApiSpec($apiSpec) - ->setApiSpecId($apiSpecId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @type \Google\Cloud\ApigeeRegistry\V1\ApiSpec $api_spec - * Required. The spec to create. - * @type string $api_spec_id - * Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The spec to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec|null - */ - public function getApiSpec() - { - return $this->api_spec; - } - - public function hasApiSpec() - { - return isset($this->api_spec); - } - - public function clearApiSpec() - { - unset($this->api_spec); - } - - /** - * Required. The spec to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $var - * @return $this - */ - public function setApiSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiSpec::class); - $this->api_spec = $var; - - return $this; - } - - /** - * Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_spec_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getApiSpecId() - { - return $this->api_spec_id; - } - - /** - * Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_spec_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setApiSpecId($var) - { - GPBUtil::checkString($var, True); - $this->api_spec_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiVersionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiVersionRequest.php deleted file mode 100644 index a364a983ba10..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateApiVersionRequest.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateApiVersionRequest - */ -class CreateApiVersionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The version to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_version = null; - /** - * Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_version_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_version_id = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion Required. The version to create. - * @param string $apiVersionId Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateApiVersionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion, string $apiVersionId): self - { - return (new self()) - ->setParent($parent) - ->setApiVersion($apiVersion) - ->setApiVersionId($apiVersionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * @type \Google\Cloud\ApigeeRegistry\V1\ApiVersion $api_version - * Required. The version to create. - * @type string $api_version_id - * Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The version to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiVersion|null - */ - public function getApiVersion() - { - return $this->api_version; - } - - public function hasApiVersion() - { - return isset($this->api_version); - } - - public function clearApiVersion() - { - unset($this->api_version); - } - - /** - * Required. The version to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiVersion::class); - $this->api_version = $var; - - return $this; - } - - /** - * Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_version_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getApiVersionId() - { - return $this->api_version_id; - } - - /** - * Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string api_version_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setApiVersionId($var) - { - GPBUtil::checkString($var, True); - $this->api_version_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateArtifactRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateArtifactRequest.php deleted file mode 100644 index 4b6f40f7857e..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateArtifactRequest.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateArtifactRequest - */ -class CreateArtifactRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The artifact to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $artifact = null; - /** - * Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string artifact_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $artifact_id = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * Please see {@see RegistryClient::locationName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact Required. The artifact to create. - * @param string $artifactId Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateArtifactRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact, string $artifactId): self - { - return (new self()) - ->setParent($parent) - ->setArtifact($artifact) - ->setArtifactId($artifactId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * @type \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact - * Required. The artifact to create. - * @type string $artifact_id - * Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The artifact to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Artifact|null - */ - public function getArtifact() - { - return $this->artifact; - } - - public function hasArtifact() - { - return isset($this->artifact); - } - - public function clearArtifact() - { - unset($this->artifact); - } - - /** - * Required. The artifact to create. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $var - * @return $this - */ - public function setArtifact($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Artifact::class); - $this->artifact = $var; - - return $this; - } - - /** - * Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string artifact_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getArtifactId() - { - return $this->artifact_id; - } - - /** - * Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * Following AIP-162, IDs must not have the form of a UUID. - * - * Generated from protobuf field string artifact_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setArtifactId($var) - { - GPBUtil::checkString($var, True); - $this->artifact_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateInstanceRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateInstanceRequest.php deleted file mode 100644 index c232f42c7835..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/CreateInstanceRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.apigeeregistry.v1.CreateInstanceRequest - */ -class CreateInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance_id = ''; - /** - * Required. The Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance instance = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance = null; - - /** - * @param string $parent Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * Please see {@see ProvisioningClient::locationName()} for help formatting this field. - * @param \Google\Cloud\ApigeeRegistry\V1\Instance $instance Required. The Instance. - * @param string $instanceId Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * - * @return \Google\Cloud\ApigeeRegistry\V1\CreateInstanceRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ApigeeRegistry\V1\Instance $instance, string $instanceId): self - { - return (new self()) - ->setParent($parent) - ->setInstance($instance) - ->setInstanceId($instanceId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * @type string $instance_id - * Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * @type \Google\Cloud\ApigeeRegistry\V1\Instance $instance - * Required. The Instance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getInstanceId() - { - return $this->instance_id; - } - - /** - * Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setInstanceId($var) - { - GPBUtil::checkString($var, True); - $this->instance_id = $var; - - return $this; - } - - /** - * Required. The Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance instance = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Instance|null - */ - public function getInstance() - { - return $this->instance; - } - - public function hasInstance() - { - return isset($this->instance); - } - - public function clearInstance() - { - unset($this->instance); - } - - /** - * Required. The Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance instance = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Instance $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Instance::class); - $this->instance = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRequest.php deleted file mode 100644 index 4ab9062cf586..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRequest.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiDeploymentRequest - */ -class DeleteApiDeploymentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - */ - protected $force = false; - - /** - * @param string $name Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRevisionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRevisionRequest.php deleted file mode 100644 index 1d309559b116..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiDeploymentRevisionRequest.php +++ /dev/null @@ -1,97 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiDeploymentRevisionRequest - */ -class DeleteApiDeploymentRevisionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRevisionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiRequest.php deleted file mode 100644 index dae30192286a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiRequest.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiRequest - */ -class DeleteApiRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - */ - protected $force = false; - - /** - * @param string $name Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRequest.php deleted file mode 100644 index 9b2e02fd42e5..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRequest.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiSpecRequest - */ -class DeleteApiSpecRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - */ - protected $force = false; - - /** - * @param string $name Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRevisionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRevisionRequest.php deleted file mode 100644 index 30ea1c28b7b1..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiSpecRevisionRequest.php +++ /dev/null @@ -1,97 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiSpecRevisionRequest - */ -class DeleteApiSpecRevisionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRevisionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiVersionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiVersionRequest.php deleted file mode 100644 index d691cfd21455..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteApiVersionRequest.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteApiVersionRequest - */ -class DeleteApiVersionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - */ - protected $force = false; - - /** - * @param string $name Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteApiVersionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * - * Generated from protobuf field bool force = 2; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteArtifactRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteArtifactRequest.php deleted file mode 100644 index fc64de397281..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteArtifactRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteArtifactRequest - */ -class DeleteArtifactRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * Please see {@see RegistryClient::artifactName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteArtifactRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteInstanceRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteInstanceRequest.php deleted file mode 100644 index 472a8ce533f3..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/DeleteInstanceRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.DeleteInstanceRequest - */ -class DeleteInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. Please see - * {@see ProvisioningClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\DeleteInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiDeploymentRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiDeploymentRequest.php deleted file mode 100644 index 6c175f9ce41c..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiDeploymentRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetApiDeploymentRequest - */ -class GetApiDeploymentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * Please see {@see RegistryClient::apiDeploymentName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetApiDeploymentRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiRequest.php deleted file mode 100644 index f6e3f7c8e321..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetApiRequest - */ -class GetApiRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetApiRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecContentsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecContentsRequest.php deleted file mode 100644 index b7e173d568cb..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecContentsRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetApiSpecContentsRequest - */ -class GetApiSpecContentsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetApiSpecContentsRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecRequest.php deleted file mode 100644 index d7df0a4e9b06..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiSpecRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetApiSpecRequest - */ -class GetApiSpecRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * Please see {@see RegistryClient::apiSpecName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetApiSpecRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiVersionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiVersionRequest.php deleted file mode 100644 index 1d5e09b8ad20..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetApiVersionRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetApiVersionRequest - */ -class GetApiVersionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetApiVersionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactContentsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactContentsRequest.php deleted file mode 100644 index 1c278a074f42..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactContentsRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetArtifactContentsRequest - */ -class GetArtifactContentsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * Please see {@see RegistryClient::artifactName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetArtifactContentsRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactRequest.php deleted file mode 100644 index fc1cc09862cc..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetArtifactRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetArtifactRequest - */ -class GetArtifactRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * Please see {@see RegistryClient::artifactName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetArtifactRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetInstanceRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetInstanceRequest.php deleted file mode 100644 index a82eda9d5780..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/GetInstanceRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.apigeeregistry.v1.GetInstanceRequest - */ -class GetInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. Please see - * {@see ProvisioningClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\GetInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance.php deleted file mode 100644 index d6b1670dec12..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance.php +++ /dev/null @@ -1,272 +0,0 @@ -google.cloud.apigeeregistry.v1.Instance - */ -class Instance extends \Google\Protobuf\Internal\Message -{ - /** - * Format: `projects/*/locations/*/instance`. - * Currently only `locations/global` is supported. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The current state of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Extra information of Instance.State if the state is `FAILED`. - * - * Generated from protobuf field string state_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state_message = ''; - /** - * Required. Config of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.Config config = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Format: `projects/*/locations/*/instance`. - * Currently only `locations/global` is supported. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation timestamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update timestamp. - * @type int $state - * Output only. The current state of the Instance. - * @type string $state_message - * Output only. Extra information of Instance.State if the state is `FAILED`. - * @type \Google\Cloud\ApigeeRegistry\V1\Instance\Config $config - * Required. Config of the Instance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * Format: `projects/*/locations/*/instance`. - * Currently only `locations/global` is supported. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Format: `projects/*/locations/*/instance`. - * Currently only `locations/global` is supported. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Creation timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Last update timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The current state of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ApigeeRegistry\V1\Instance\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Extra information of Instance.State if the state is `FAILED`. - * - * Generated from protobuf field string state_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStateMessage() - { - return $this->state_message; - } - - /** - * Output only. Extra information of Instance.State if the state is `FAILED`. - * - * Generated from protobuf field string state_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStateMessage($var) - { - GPBUtil::checkString($var, True); - $this->state_message = $var; - - return $this; - } - - /** - * Required. Config of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.Config config = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Instance\Config|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Required. Config of the Instance. - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Instance.Config config = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Instance\Config $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Instance\Config::class); - $this->config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/Config.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/Config.php deleted file mode 100644 index b9d5538203fe..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/Config.php +++ /dev/null @@ -1,116 +0,0 @@ -google.cloud.apigeeregistry.v1.Instance.Config - */ -class Config extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The GCP location where the Instance resides. - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $location = ''; - /** - * Required. The Customer Managed Encryption Key (CMEK) used for data encryption. - * The CMEK name should follow the format of - * `projects/([^/]+)/locations/([^/]+)/keyRings/([^/]+)/cryptoKeys/([^/]+)`, - * where the `location` must match InstanceConfig.location. - * - * Generated from protobuf field string cmek_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cmek_key_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $location - * Output only. The GCP location where the Instance resides. - * @type string $cmek_key_name - * Required. The Customer Managed Encryption Key (CMEK) used for data encryption. - * The CMEK name should follow the format of - * `projects/([^/]+)/locations/([^/]+)/keyRings/([^/]+)/cryptoKeys/([^/]+)`, - * where the `location` must match InstanceConfig.location. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The GCP location where the Instance resides. - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * Output only. The GCP location where the Instance resides. - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - - /** - * Required. The Customer Managed Encryption Key (CMEK) used for data encryption. - * The CMEK name should follow the format of - * `projects/([^/]+)/locations/([^/]+)/keyRings/([^/]+)/cryptoKeys/([^/]+)`, - * where the `location` must match InstanceConfig.location. - * - * Generated from protobuf field string cmek_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCmekKeyName() - { - return $this->cmek_key_name; - } - - /** - * Required. The Customer Managed Encryption Key (CMEK) used for data encryption. - * The CMEK name should follow the format of - * `projects/([^/]+)/locations/([^/]+)/keyRings/([^/]+)/cryptoKeys/([^/]+)`, - * where the `location` must match InstanceConfig.location. - * - * Generated from protobuf field string cmek_key_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCmekKeyName($var) - { - GPBUtil::checkString($var, True); - $this->cmek_key_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Config::class, \Google\Cloud\ApigeeRegistry\V1\Instance_Config::class); - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/State.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/State.php deleted file mode 100644 index ce20920eecf0..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance/State.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.apigeeregistry.v1.Instance.State - */ -class State -{ - /** - * The default value. This value is used if the state is omitted. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The Instance has not been initialized or has been deleted. - * - * Generated from protobuf enum INACTIVE = 1; - */ - const INACTIVE = 1; - /** - * The Instance is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The Instance has been created and is ready for use. - * - * Generated from protobuf enum ACTIVE = 3; - */ - const ACTIVE = 3; - /** - * The Instance is being updated. - * - * Generated from protobuf enum UPDATING = 4; - */ - const UPDATING = 4; - /** - * The Instance is being deleted. - * - * Generated from protobuf enum DELETING = 5; - */ - const DELETING = 5; - /** - * The Instance encountered an error during a state change. - * - * Generated from protobuf enum FAILED = 6; - */ - const FAILED = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::INACTIVE => 'INACTIVE', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\ApigeeRegistry\V1\Instance_State::class); - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance_Config.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance_Config.php deleted file mode 100644 index 78af2c4b0d96..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/Instance_Config.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiDeploymentRevisionsRequest - */ -class ListApiDeploymentRevisionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the deployment to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token, received from a previous ListApiDeploymentRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the deployment to list revisions for. - * @type int $page_size - * The maximum number of revisions to return per page. - * @type string $page_token - * The page token, received from a previous ListApiDeploymentRevisions call. - * Provide this to retrieve the subsequent page. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the deployment to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the deployment to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token, received from a previous ListApiDeploymentRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token, received from a previous ListApiDeploymentRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentRevisionsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentRevisionsResponse.php deleted file mode 100644 index cdd6bf172695..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentRevisionsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiDeploymentRevisionsResponse - */ -class ListApiDeploymentRevisionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The revisions of the deployment. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - */ - private $api_deployments; - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\ApiDeployment>|\Google\Protobuf\Internal\RepeatedField $api_deployments - * The revisions of the deployment. - * @type string $next_page_token - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The revisions of the deployment. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiDeployments() - { - return $this->api_deployments; - } - - /** - * The revisions of the deployment. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\ApiDeployment>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiDeployments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment::class); - $this->api_deployments = $arr; - - return $this; - } - - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsRequest.php deleted file mode 100644 index 5835a7b5de67..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiDeploymentsRequest - */ -class ListApiDeploymentsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of deployments to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListApiDeployments` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiDeployments` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * @type int $page_size - * The maximum number of deployments to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListApiDeployments` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiDeployments` must - * match the call that provided the page token. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of deployments to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of deployments to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListApiDeployments` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiDeployments` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListApiDeployments` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiDeployments` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsResponse.php deleted file mode 100644 index 826babba612a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiDeploymentsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiDeploymentsResponse - */ -class ListApiDeploymentsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The deployments from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - */ - private $api_deployments; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\ApiDeployment>|\Google\Protobuf\Internal\RepeatedField $api_deployments - * The deployments from the specified publisher. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The deployments from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiDeployments() - { - return $this->api_deployments; - } - - /** - * The deployments from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiDeployment api_deployments = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\ApiDeployment>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiDeployments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment::class); - $this->api_deployments = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsRequest.php deleted file mode 100644 index c68a6511d7d2..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiSpecRevisionsRequest - */ -class ListApiSpecRevisionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token, received from a previous ListApiSpecRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec to list revisions for. - * @type int $page_size - * The maximum number of revisions to return per page. - * @type string $page_token - * The page token, received from a previous ListApiSpecRevisions call. - * Provide this to retrieve the subsequent page. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec to list revisions for. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of revisions to return per page. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token, received from a previous ListApiSpecRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token, received from a previous ListApiSpecRevisions call. - * Provide this to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsResponse.php deleted file mode 100644 index bff3c8059de3..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecRevisionsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiSpecRevisionsResponse - */ -class ListApiSpecRevisionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The revisions of the spec. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - */ - private $api_specs; - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\ApiSpec>|\Google\Protobuf\Internal\RepeatedField $api_specs - * The revisions of the spec. - * @type string $next_page_token - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The revisions of the spec. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiSpecs() - { - return $this->api_specs; - } - - /** - * The revisions of the spec. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\ApiSpec>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiSpecs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\ApiSpec::class); - $this->api_specs = $arr; - - return $this; - } - - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token that can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsRequest.php deleted file mode 100644 index aec5dd0220ef..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiSpecsRequest - */ -class ListApiSpecsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of specs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListApiSpecs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiSpecs` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * Please see {@see RegistryClient::apiVersionName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\ListApiSpecsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @type int $page_size - * The maximum number of specs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListApiSpecs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiSpecs` must match - * the call that provided the page token. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of specs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of specs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListApiSpecs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiSpecs` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListApiSpecs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiSpecs` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsResponse.php deleted file mode 100644 index 0e50209602ce..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiSpecsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiSpecsResponse - */ -class ListApiSpecsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The specs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - */ - private $api_specs; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\ApiSpec>|\Google\Protobuf\Internal\RepeatedField $api_specs - * The specs from the specified publisher. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The specs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiSpecs() - { - return $this->api_specs; - } - - /** - * The specs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiSpec api_specs = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\ApiSpec>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiSpecs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\ApiSpec::class); - $this->api_specs = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsRequest.php deleted file mode 100644 index bb2f87f59f83..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiVersionsRequest - */ -class ListApiVersionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of versions to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListApiVersions` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiVersions` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * Please see {@see RegistryClient::apiName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\ListApiVersionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * @type int $page_size - * The maximum number of versions to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListApiVersions` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiVersions` must - * match the call that provided the page token. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of versions to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of versions to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListApiVersions` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiVersions` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListApiVersions` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApiVersions` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsResponse.php deleted file mode 100644 index 8c9d9fd14914..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApiVersionsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApiVersionsResponse - */ -class ListApiVersionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiVersion api_versions = 1; - */ - private $api_versions; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\ApiVersion>|\Google\Protobuf\Internal\RepeatedField $api_versions - * The versions from the specified publisher. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiVersion api_versions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApiVersions() - { - return $this->api_versions; - } - - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.ApiVersion api_versions = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\ApiVersion>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApiVersions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\ApiVersion::class); - $this->api_versions = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisRequest.php deleted file mode 100644 index 38d6263b8ecf..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApisRequest - */ -class ListApisRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of APIs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListApis` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApis` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * Please see {@see RegistryClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\ListApisRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * @type int $page_size - * The maximum number of APIs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListApis` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApis` must match - * the call that provided the page token. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of APIs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of APIs to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListApis` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApis` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListApis` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListApis` must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisResponse.php deleted file mode 100644 index 83e9e5b911fd..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListApisResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListApisResponse - */ -class ListApisResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The APIs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Api apis = 1; - */ - private $apis; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\Api>|\Google\Protobuf\Internal\RepeatedField $apis - * The APIs from the specified publisher. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The APIs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Api apis = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApis() - { - return $this->apis; - } - - /** - * The APIs from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Api apis = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\Api>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApis($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\Api::class); - $this->apis = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsRequest.php deleted file mode 100644 index dc72036104bd..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.apigeeregistry.v1.ListArtifactsRequest - */ -class ListArtifactsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of artifacts to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListArtifacts` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListArtifacts` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * Please see {@see RegistryClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\ApigeeRegistry\V1\ListArtifactsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * @type int $page_size - * The maximum number of artifacts to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListArtifacts` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListArtifacts` must - * match the call that provided the page token. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of artifacts to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of artifacts to return. - * The service may return fewer than this value. - * If unspecified, at most 50 values will be returned. - * The maximum is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListArtifacts` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListArtifacts` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListArtifacts` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListArtifacts` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsResponse.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsResponse.php deleted file mode 100644 index 24a8dd8f3843..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ListArtifactsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.ListArtifactsResponse - */ -class ListArtifactsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The artifacts from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Artifact artifacts = 1; - */ - private $artifacts; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ApigeeRegistry\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $artifacts - * The artifacts from the specified publisher. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * The artifacts from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Artifact artifacts = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArtifacts() - { - return $this->artifacts; - } - - /** - * The artifacts from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.apigeeregistry.v1.Artifact artifacts = 1; - * @param array<\Google\Cloud\ApigeeRegistry\V1\Artifact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArtifacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ApigeeRegistry\V1\Artifact::class); - $this->artifacts = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/OperationMetadata.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/OperationMetadata.php deleted file mode 100644 index a6f59492977b..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/OperationMetadata.php +++ /dev/null @@ -1,303 +0,0 @@ -google.cloud.apigeeregistry.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - */ - protected $create_time = null; - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - */ - protected $end_time = null; - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - */ - protected $target = ''; - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - */ - protected $verb = ''; - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - */ - protected $status_message = ''; - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool cancellation_requested = 6; - */ - protected $cancellation_requested = false; - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * The time the operation finished running. - * @type string $target - * Server-defined resource path for the target of the operation. - * @type string $verb - * Name of the verb executed by the operation. - * @type string $status_message - * Human-readable status of the operation, if any. - * @type bool $cancellation_requested - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * @type string $api_version - * API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\ProvisioningService::initOnce(); - parent::__construct($data); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool cancellation_requested = 6; - * @return bool - */ - public function getCancellationRequested() - { - return $this->cancellation_requested; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool cancellation_requested = 6; - * @param bool $var - * @return $this - */ - public function setCancellationRequested($var) - { - GPBUtil::checkBool($var); - $this->cancellation_requested = $var; - - return $this; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ProvisioningGrpcClient.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ProvisioningGrpcClient.php deleted file mode 100644 index 1ca374bb07fc..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ProvisioningGrpcClient.php +++ /dev/null @@ -1,81 +0,0 @@ -_simpleRequest('/google.cloud.apigeeregistry.v1.Provisioning/CreateInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes the Registry instance. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteInstance(\Google\Cloud\ApigeeRegistry\V1\DeleteInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Provisioning/DeleteInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single Instance. - * @param \Google\Cloud\ApigeeRegistry\V1\GetInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetInstance(\Google\Cloud\ApigeeRegistry\V1\GetInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Provisioning/GetInstance', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Instance', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RegistryGrpcClient.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RegistryGrpcClient.php deleted file mode 100644 index 3d9bc9f16308..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RegistryGrpcClient.php +++ /dev/null @@ -1,575 +0,0 @@ -_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApis', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApisResponse', 'decode'], - $metadata, $options); - } - - /** - * Returns a specified API. - * @param \Google\Cloud\ApigeeRegistry\V1\GetApiRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetApi(\Google\Cloud\ApigeeRegistry\V1\GetApiRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetApi', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Api', 'decode'], - $metadata, $options); - } - - /** - * Creates a specified API. - * @param \Google\Cloud\ApigeeRegistry\V1\CreateApiRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateApi(\Google\Cloud\ApigeeRegistry\V1\CreateApiRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/CreateApi', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Api', 'decode'], - $metadata, $options); - } - - /** - * Used to modify a specified API. - * @param \Google\Cloud\ApigeeRegistry\V1\UpdateApiRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateApi(\Google\Cloud\ApigeeRegistry\V1\UpdateApiRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/UpdateApi', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Api', 'decode'], - $metadata, $options); - } - - /** - * Removes a specified API and all of the resources that it - * owns. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApi(\Google\Cloud\ApigeeRegistry\V1\DeleteApiRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApi', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Returns matching versions. - * @param \Google\Cloud\ApigeeRegistry\V1\ListApiVersionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListApiVersions(\Google\Cloud\ApigeeRegistry\V1\ListApiVersionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApiVersions', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApiVersionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Returns a specified version. - * @param \Google\Cloud\ApigeeRegistry\V1\GetApiVersionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetApiVersion(\Google\Cloud\ApigeeRegistry\V1\GetApiVersionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetApiVersion', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiVersion', 'decode'], - $metadata, $options); - } - - /** - * Creates a specified version. - * @param \Google\Cloud\ApigeeRegistry\V1\CreateApiVersionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateApiVersion(\Google\Cloud\ApigeeRegistry\V1\CreateApiVersionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/CreateApiVersion', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiVersion', 'decode'], - $metadata, $options); - } - - /** - * Used to modify a specified version. - * @param \Google\Cloud\ApigeeRegistry\V1\UpdateApiVersionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateApiVersion(\Google\Cloud\ApigeeRegistry\V1\UpdateApiVersionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/UpdateApiVersion', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiVersion', 'decode'], - $metadata, $options); - } - - /** - * Removes a specified version and all of the resources that - * it owns. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiVersionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApiVersion(\Google\Cloud\ApigeeRegistry\V1\DeleteApiVersionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApiVersion', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Returns matching specs. - * @param \Google\Cloud\ApigeeRegistry\V1\ListApiSpecsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListApiSpecs(\Google\Cloud\ApigeeRegistry\V1\ListApiSpecsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApiSpecs', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApiSpecsResponse', 'decode'], - $metadata, $options); - } - - /** - * Returns a specified spec. - * @param \Google\Cloud\ApigeeRegistry\V1\GetApiSpecRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetApiSpec(\Google\Cloud\ApigeeRegistry\V1\GetApiSpecRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetApiSpec', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Returns the contents of a specified spec. - * If specs are stored with GZip compression, the default behavior - * is to return the spec uncompressed (the mime_type response field - * indicates the exact format returned). - * @param \Google\Cloud\ApigeeRegistry\V1\GetApiSpecContentsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetApiSpecContents(\Google\Cloud\ApigeeRegistry\V1\GetApiSpecContentsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetApiSpecContents', - $argument, - ['\Google\Api\HttpBody', 'decode'], - $metadata, $options); - } - - /** - * Creates a specified spec. - * @param \Google\Cloud\ApigeeRegistry\V1\CreateApiSpecRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateApiSpec(\Google\Cloud\ApigeeRegistry\V1\CreateApiSpecRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/CreateApiSpec', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Used to modify a specified spec. - * @param \Google\Cloud\ApigeeRegistry\V1\UpdateApiSpecRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateApiSpec(\Google\Cloud\ApigeeRegistry\V1\UpdateApiSpecRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/UpdateApiSpec', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Removes a specified spec, all revisions, and all child - * resources (e.g., artifacts). - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApiSpec(\Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApiSpec', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Adds a tag to a specified revision of a spec. - * @param \Google\Cloud\ApigeeRegistry\V1\TagApiSpecRevisionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TagApiSpecRevision(\Google\Cloud\ApigeeRegistry\V1\TagApiSpecRevisionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/TagApiSpecRevision', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Lists all revisions of a spec. - * Revisions are returned in descending order of revision creation time. - * @param \Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListApiSpecRevisions(\Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApiSpecRevisions', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Sets the current revision to a specified prior revision. - * Note that this creates a new revision with a new revision ID. - * @param \Google\Cloud\ApigeeRegistry\V1\RollbackApiSpecRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RollbackApiSpec(\Google\Cloud\ApigeeRegistry\V1\RollbackApiSpecRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/RollbackApiSpec', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Deletes a revision of a spec. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRevisionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApiSpecRevision(\Google\Cloud\ApigeeRegistry\V1\DeleteApiSpecRevisionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApiSpecRevision', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiSpec', 'decode'], - $metadata, $options); - } - - /** - * Returns matching deployments. - * @param \Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListApiDeployments(\Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApiDeployments', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsResponse', 'decode'], - $metadata, $options); - } - - /** - * Returns a specified deployment. - * @param \Google\Cloud\ApigeeRegistry\V1\GetApiDeploymentRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetApiDeployment(\Google\Cloud\ApigeeRegistry\V1\GetApiDeploymentRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetApiDeployment', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Creates a specified deployment. - * @param \Google\Cloud\ApigeeRegistry\V1\CreateApiDeploymentRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateApiDeployment(\Google\Cloud\ApigeeRegistry\V1\CreateApiDeploymentRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/CreateApiDeployment', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Used to modify a specified deployment. - * @param \Google\Cloud\ApigeeRegistry\V1\UpdateApiDeploymentRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateApiDeployment(\Google\Cloud\ApigeeRegistry\V1\UpdateApiDeploymentRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/UpdateApiDeployment', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Removes a specified deployment, all revisions, and all - * child resources (e.g., artifacts). - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApiDeployment(\Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApiDeployment', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Adds a tag to a specified revision of a - * deployment. - * @param \Google\Cloud\ApigeeRegistry\V1\TagApiDeploymentRevisionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TagApiDeploymentRevision(\Google\Cloud\ApigeeRegistry\V1\TagApiDeploymentRevisionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/TagApiDeploymentRevision', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Lists all revisions of a deployment. - * Revisions are returned in descending order of revision creation time. - * @param \Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListApiDeploymentRevisions(\Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListApiDeploymentRevisions', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Sets the current revision to a specified prior - * revision. Note that this creates a new revision with a new revision ID. - * @param \Google\Cloud\ApigeeRegistry\V1\RollbackApiDeploymentRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RollbackApiDeployment(\Google\Cloud\ApigeeRegistry\V1\RollbackApiDeploymentRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/RollbackApiDeployment', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Deletes a revision of a deployment. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRevisionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteApiDeploymentRevision(\Google\Cloud\ApigeeRegistry\V1\DeleteApiDeploymentRevisionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteApiDeploymentRevision', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ApiDeployment', 'decode'], - $metadata, $options); - } - - /** - * Returns matching artifacts. - * @param \Google\Cloud\ApigeeRegistry\V1\ListArtifactsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListArtifacts(\Google\Cloud\ApigeeRegistry\V1\ListArtifactsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ListArtifacts', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\ListArtifactsResponse', 'decode'], - $metadata, $options); - } - - /** - * Returns a specified artifact. - * @param \Google\Cloud\ApigeeRegistry\V1\GetArtifactRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetArtifact(\Google\Cloud\ApigeeRegistry\V1\GetArtifactRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetArtifact', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Artifact', 'decode'], - $metadata, $options); - } - - /** - * Returns the contents of a specified artifact. - * If artifacts are stored with GZip compression, the default behavior - * is to return the artifact uncompressed (the mime_type response field - * indicates the exact format returned). - * @param \Google\Cloud\ApigeeRegistry\V1\GetArtifactContentsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetArtifactContents(\Google\Cloud\ApigeeRegistry\V1\GetArtifactContentsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/GetArtifactContents', - $argument, - ['\Google\Api\HttpBody', 'decode'], - $metadata, $options); - } - - /** - * Creates a specified artifact. - * @param \Google\Cloud\ApigeeRegistry\V1\CreateArtifactRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateArtifact(\Google\Cloud\ApigeeRegistry\V1\CreateArtifactRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/CreateArtifact', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Artifact', 'decode'], - $metadata, $options); - } - - /** - * Used to replace a specified artifact. - * @param \Google\Cloud\ApigeeRegistry\V1\ReplaceArtifactRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ReplaceArtifact(\Google\Cloud\ApigeeRegistry\V1\ReplaceArtifactRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/ReplaceArtifact', - $argument, - ['\Google\Cloud\ApigeeRegistry\V1\Artifact', 'decode'], - $metadata, $options); - } - - /** - * Removes a specified artifact. - * @param \Google\Cloud\ApigeeRegistry\V1\DeleteArtifactRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteArtifact(\Google\Cloud\ApigeeRegistry\V1\DeleteArtifactRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.apigeeregistry.v1.Registry/DeleteArtifact', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ReplaceArtifactRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ReplaceArtifactRequest.php deleted file mode 100644 index 1d009819b815..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/ReplaceArtifactRequest.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.apigeeregistry.v1.ReplaceArtifactRequest - */ -class ReplaceArtifactRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The artifact to replace. - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $artifact = null; - - /** - * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact Required. The artifact to replace. - * - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * - * @return \Google\Cloud\ApigeeRegistry\V1\ReplaceArtifactRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApigeeRegistry\V1\Artifact $artifact): self - { - return (new self()) - ->setArtifact($artifact); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApigeeRegistry\V1\Artifact $artifact - * Required. The artifact to replace. - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The artifact to replace. - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Artifact|null - */ - public function getArtifact() - { - return $this->artifact; - } - - public function hasArtifact() - { - return isset($this->artifact); - } - - public function clearArtifact() - { - unset($this->artifact); - } - - /** - * Required. The artifact to replace. - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Artifact artifact = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Artifact $var - * @return $this - */ - public function setArtifact($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Artifact::class); - $this->artifact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiDeploymentRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiDeploymentRequest.php deleted file mode 100644 index 6dc4037fe5f4..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiDeploymentRequest.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.apigeeregistry.v1.RollbackApiDeploymentRequest - */ -class RollbackApiDeploymentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The deployment being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same deployment. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $revision_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The deployment being rolled back. - * @type string $revision_id - * Required. The revision ID to roll back to. - * It must be a revision of the same deployment. - * Example: `c7cfa2a8` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The deployment being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The deployment being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same deployment. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same deployment. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiSpecRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiSpecRequest.php deleted file mode 100644 index fefe0e7930c9..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/RollbackApiSpecRequest.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.apigeeregistry.v1.RollbackApiSpecRequest - */ -class RollbackApiSpecRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The spec being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same spec. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $revision_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The spec being rolled back. - * @type string $revision_id - * Required. The revision ID to roll back to. - * It must be a revision of the same spec. - * Example: `c7cfa2a8` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The spec being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The spec being rolled back. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same spec. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Required. The revision ID to roll back to. - * It must be a revision of the same spec. - * Example: `c7cfa2a8` - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiDeploymentRevisionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiDeploymentRevisionRequest.php deleted file mode 100644 index e838411654ab..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiDeploymentRevisionRequest.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.TagApiDeploymentRevisionRequest - */ -class TagApiDeploymentRevisionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the deployment to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the deployment to be tagged, including the revision ID. - * @type string $tag - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the deployment to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the deployment to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTag() - { - return $this->tag; - } - - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTag($var) - { - GPBUtil::checkString($var, True); - $this->tag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiSpecRevisionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiSpecRevisionRequest.php deleted file mode 100644 index 741623a33dd0..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/TagApiSpecRevisionRequest.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.apigeeregistry.v1.TagApiSpecRevisionRequest - */ -class TagApiSpecRevisionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the spec to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the spec to be tagged, including the revision ID. - * @type string $tag - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the spec to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the spec to be tagged, including the revision ID. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTag() - { - return $this->tag; - } - - /** - * Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * - * Generated from protobuf field string tag = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTag($var) - { - GPBUtil::checkString($var, True); - $this->tag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiDeploymentRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiDeploymentRequest.php deleted file mode 100644 index c569dd3097af..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiDeploymentRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.cloud.apigeeregistry.v1.UpdateApiDeploymentRequest - */ -class UpdateApiDeploymentRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The deployment to update. - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_deployment = null; - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true, and the deployment is not found, a new deployment will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment Required. The deployment to update. - * - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiDeploymentRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiDeployment $apiDeployment, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setApiDeployment($apiDeployment) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $api_deployment - * Required. The deployment to update. - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allow_missing - * If set to true, and the deployment is not found, a new deployment will be - * created. In this situation, `update_mask` is ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The deployment to update. - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment|null - */ - public function getApiDeployment() - { - return $this->api_deployment; - } - - public function hasApiDeployment() - { - return isset($this->api_deployment); - } - - public function clearApiDeployment() - { - unset($this->api_deployment); - } - - /** - * Required. The deployment to update. - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiDeployment api_deployment = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiDeployment $var - * @return $this - */ - public function setApiDeployment($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiDeployment::class); - $this->api_deployment = $var; - - return $this; - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true, and the deployment is not found, a new deployment will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the deployment is not found, a new deployment will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiRequest.php deleted file mode 100644 index 1f848f001408..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.cloud.apigeeregistry.v1.UpdateApiRequest - */ -class UpdateApiRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The API to update. - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api = null; - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true, and the API is not found, a new API will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\ApigeeRegistry\V1\Api $api Required. The API to update. - * - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApigeeRegistry\V1\Api $api, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setApi($api) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApigeeRegistry\V1\Api $api - * Required. The API to update. - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allow_missing - * If set to true, and the API is not found, a new API will be created. - * In this situation, `update_mask` is ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The API to update. - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\Api|null - */ - public function getApi() - { - return $this->api; - } - - public function hasApi() - { - return isset($this->api); - } - - public function clearApi() - { - unset($this->api); - } - - /** - * Required. The API to update. - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.Api api = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\Api $var - * @return $this - */ - public function setApi($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\Api::class); - $this->api = $var; - - return $this; - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true, and the API is not found, a new API will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the API is not found, a new API will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiSpecRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiSpecRequest.php deleted file mode 100644 index 1aa6e58d7ee3..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiSpecRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.cloud.apigeeregistry.v1.UpdateApiSpecRequest - */ -class UpdateApiSpecRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The spec to update. - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_spec = null; - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true, and the spec is not found, a new spec will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec Required. The spec to update. - * - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiSpecRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiSpec $apiSpec, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setApiSpec($apiSpec) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApigeeRegistry\V1\ApiSpec $api_spec - * Required. The spec to update. - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allow_missing - * If set to true, and the spec is not found, a new spec will be created. - * In this situation, `update_mask` is ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The spec to update. - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec|null - */ - public function getApiSpec() - { - return $this->api_spec; - } - - public function hasApiSpec() - { - return isset($this->api_spec); - } - - public function clearApiSpec() - { - unset($this->api_spec); - } - - /** - * Required. The spec to update. - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiSpec api_spec = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiSpec $var - * @return $this - */ - public function setApiSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiSpec::class); - $this->api_spec = $var; - - return $this; - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true, and the spec is not found, a new spec will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the spec is not found, a new spec will be created. - * In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiVersionRequest.php b/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiVersionRequest.php deleted file mode 100644 index f83ae4b5ff6e..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/proto/src/Google/Cloud/ApigeeRegistry/V1/UpdateApiVersionRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.cloud.apigeeregistry.v1.UpdateApiVersionRequest - */ -class UpdateApiVersionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The version to update. - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_version = null; - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true, and the version is not found, a new version will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion Required. The version to update. - * - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * @return \Google\Cloud\ApigeeRegistry\V1\UpdateApiVersionRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ApigeeRegistry\V1\ApiVersion $apiVersion, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setApiVersion($apiVersion) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ApigeeRegistry\V1\ApiVersion $api_version - * Required. The version to update. - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allow_missing - * If set to true, and the version is not found, a new version will be - * created. In this situation, `update_mask` is ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Apigeeregistry\V1\RegistryService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The version to update. - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ApigeeRegistry\V1\ApiVersion|null - */ - public function getApiVersion() - { - return $this->api_version; - } - - public function hasApiVersion() - { - return isset($this->api_version); - } - - public function clearApiVersion() - { - unset($this->api_version); - } - - /** - * Required. The version to update. - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * - * Generated from protobuf field .google.cloud.apigeeregistry.v1.ApiVersion api_version = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ApigeeRegistry\V1\ApiVersion $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ApigeeRegistry\V1\ApiVersion::class); - $this->api_version = $var; - - return $this; - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true, and the version is not found, a new version will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the version is not found, a new version will be - * created. In this situation, `update_mask` is ignored. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/create_instance.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/create_instance.php deleted file mode 100644 index 8d625123fb7a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/create_instance.php +++ /dev/null @@ -1,101 +0,0 @@ -setCmekKeyName($instanceConfigCmekKeyName); - $instance = (new Instance()) - ->setConfig($instanceConfig); - $request = (new CreateInstanceRequest()) - ->setParent($formattedParent) - ->setInstanceId($instanceId) - ->setInstance($instance); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $provisioningClient->createInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 = ProvisioningClient::locationName('[PROJECT]', '[LOCATION]'); - $instanceId = '[INSTANCE_ID]'; - $instanceConfigCmekKeyName = '[CMEK_KEY_NAME]'; - - create_instance_sample($formattedParent, $instanceId, $instanceConfigCmekKeyName); -} -// [END apigeeregistry_v1_generated_Provisioning_CreateInstance_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/delete_instance.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/delete_instance.php deleted file mode 100644 index 458f61a515b1..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/delete_instance.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $provisioningClient->deleteInstance($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 = ProvisioningClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - delete_instance_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Provisioning_DeleteInstance_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_iam_policy.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_iam_policy.php deleted file mode 100644 index 34e6892e22f9..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $provisioningClient->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); -} -// [END apigeeregistry_v1_generated_Provisioning_GetIamPolicy_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_instance.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_instance.php deleted file mode 100644 index 3665469d8d99..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_instance.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Instance $response */ - $response = $provisioningClient->getInstance($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 = ProvisioningClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - get_instance_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Provisioning_GetInstance_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_location.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_location.php deleted file mode 100644 index e661b5e8f8a1..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Provisioning_GetLocation_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/list_locations.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/list_locations.php deleted file mode 100644 index edbf5b19c7b3..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Provisioning_ListLocations_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/set_iam_policy.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/set_iam_policy.php deleted file mode 100644 index f0cb3b8f4f89..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $provisioningClient->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); -} -// [END apigeeregistry_v1_generated_Provisioning_SetIamPolicy_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/test_iam_permissions.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/test_iam_permissions.php deleted file mode 100644 index 617ca74f46e7..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/ProvisioningClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $provisioningClient->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); -} -// [END apigeeregistry_v1_generated_Provisioning_TestIamPermissions_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api.php deleted file mode 100644 index b953dae0e144..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent) - ->setApi($api) - ->setApiId($apiId); - - // Call the API and handle any network failures. - try { - /** @var Api $response */ - $response = $registryClient->createApi($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 = RegistryClient::locationName('[PROJECT]', '[LOCATION]'); - $apiId = '[API_ID]'; - - create_api_sample($formattedParent, $apiId); -} -// [END apigeeregistry_v1_generated_Registry_CreateApi_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_deployment.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_deployment.php deleted file mode 100644 index d7ba6a32e587..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_deployment.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent) - ->setApiDeployment($apiDeployment) - ->setApiDeploymentId($apiDeploymentId); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->createApiDeployment($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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiDeploymentId = '[API_DEPLOYMENT_ID]'; - - create_api_deployment_sample($formattedParent, $apiDeploymentId); -} -// [END apigeeregistry_v1_generated_Registry_CreateApiDeployment_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_spec.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_spec.php deleted file mode 100644 index cb60fbb2e4d6..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_spec.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent) - ->setApiSpec($apiSpec) - ->setApiSpecId($apiSpecId); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->createApiSpec($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 = RegistryClient::apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $apiSpecId = '[API_SPEC_ID]'; - - create_api_spec_sample($formattedParent, $apiSpecId); -} -// [END apigeeregistry_v1_generated_Registry_CreateApiSpec_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_version.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_version.php deleted file mode 100644 index aee9a3608fd7..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_api_version.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent) - ->setApiVersion($apiVersion) - ->setApiVersionId($apiVersionId); - - // Call the API and handle any network failures. - try { - /** @var ApiVersion $response */ - $response = $registryClient->createApiVersion($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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiVersionId = '[API_VERSION_ID]'; - - create_api_version_sample($formattedParent, $apiVersionId); -} -// [END apigeeregistry_v1_generated_Registry_CreateApiVersion_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_artifact.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_artifact.php deleted file mode 100644 index 8626ae70b78b..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/create_artifact.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent) - ->setArtifact($artifact) - ->setArtifactId($artifactId); - - // Call the API and handle any network failures. - try { - /** @var Artifact $response */ - $response = $registryClient->createArtifact($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 = RegistryClient::locationName('[PROJECT]', '[LOCATION]'); - $artifactId = '[ARTIFACT_ID]'; - - create_artifact_sample($formattedParent, $artifactId); -} -// [END apigeeregistry_v1_generated_Registry_CreateArtifact_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api.php deleted file mode 100644 index 5b41a95e44d5..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $registryClient->deleteApi($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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - - delete_api_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApi_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment.php deleted file mode 100644 index 3d1bf7372084..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $registryClient->deleteApiDeployment($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 = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - - delete_api_deployment_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApiDeployment_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment_revision.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment_revision.php deleted file mode 100644 index 72f0ae7c3c05..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_deployment_revision.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->deleteApiDeploymentRevision($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 = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - - delete_api_deployment_revision_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApiDeploymentRevision_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec.php deleted file mode 100644 index 7394143ac235..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $registryClient->deleteApiSpec($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - - delete_api_spec_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApiSpec_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec_revision.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec_revision.php deleted file mode 100644 index 80cf0239f99e..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_spec_revision.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->deleteApiSpecRevision($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - - delete_api_spec_revision_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApiSpecRevision_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_version.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_version.php deleted file mode 100644 index b054d9b83526..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_api_version.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $registryClient->deleteApiVersion($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 = RegistryClient::apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - - delete_api_version_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteApiVersion_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_artifact.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_artifact.php deleted file mode 100644 index cc8e679e8994..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/delete_artifact.php +++ /dev/null @@ -1,70 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $registryClient->deleteArtifact($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 = RegistryClient::artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - - delete_artifact_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_DeleteArtifact_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api.php deleted file mode 100644 index 904cc5805c7a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Api $response */ - $response = $registryClient->getApi($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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - - get_api_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetApi_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_deployment.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_deployment.php deleted file mode 100644 index 9cc2515849c3..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_deployment.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->getApiDeployment($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 = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - - get_api_deployment_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetApiDeployment_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec.php deleted file mode 100644 index 047537061136..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->getApiSpec($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - - get_api_spec_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetApiSpec_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec_contents.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec_contents.php deleted file mode 100644 index cb205c603e9a..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_spec_contents.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var HttpBody $response */ - $response = $registryClient->getApiSpecContents($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - - get_api_spec_contents_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetApiSpecContents_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_version.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_version.php deleted file mode 100644 index e104af201c72..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_api_version.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ApiVersion $response */ - $response = $registryClient->getApiVersion($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 = RegistryClient::apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - - get_api_version_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetApiVersion_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact.php deleted file mode 100644 index b4ef1dfcd520..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Artifact $response */ - $response = $registryClient->getArtifact($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 = RegistryClient::artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - - get_artifact_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetArtifact_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact_contents.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact_contents.php deleted file mode 100644 index 2d2aab095614..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_artifact_contents.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var HttpBody $response */ - $response = $registryClient->getArtifactContents($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 = RegistryClient::artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - - get_artifact_contents_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_GetArtifactContents_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_iam_policy.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_iam_policy.php deleted file mode 100644 index 0b4190beb9b9..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $registryClient->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); -} -// [END apigeeregistry_v1_generated_Registry_GetIamPolicy_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_location.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_location.php deleted file mode 100644 index b8ded8bf66eb..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_GetLocation_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployment_revisions.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployment_revisions.php deleted file mode 100644 index 58aa0b9a066e..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployment_revisions.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApiDeploymentRevisions($request); - - /** @var ApiDeployment $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 -{ - $formattedName = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - - list_api_deployment_revisions_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_ListApiDeploymentRevisions_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployments.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployments.php deleted file mode 100644 index e5f21c1c04db..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_deployments.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApiDeployments($request); - - /** @var ApiDeployment $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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - - list_api_deployments_sample($formattedParent); -} -// [END apigeeregistry_v1_generated_Registry_ListApiDeployments_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_spec_revisions.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_spec_revisions.php deleted file mode 100644 index 7700dce9137c..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_spec_revisions.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApiSpecRevisions($request); - - /** @var ApiSpec $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 -{ - $formattedName = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - - list_api_spec_revisions_sample($formattedName); -} -// [END apigeeregistry_v1_generated_Registry_ListApiSpecRevisions_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_specs.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_specs.php deleted file mode 100644 index b10cbb784546..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_specs.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApiSpecs($request); - - /** @var ApiSpec $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 = RegistryClient::apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - - list_api_specs_sample($formattedParent); -} -// [END apigeeregistry_v1_generated_Registry_ListApiSpecs_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_versions.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_versions.php deleted file mode 100644 index 746717b85fcd..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_api_versions.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApiVersions($request); - - /** @var ApiVersion $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 = RegistryClient::apiName('[PROJECT]', '[LOCATION]', '[API]'); - - list_api_versions_sample($formattedParent); -} -// [END apigeeregistry_v1_generated_Registry_ListApiVersions_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_apis.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_apis.php deleted file mode 100644 index 50154d398f86..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_apis.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listApis($request); - - /** @var Api $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 = RegistryClient::locationName('[PROJECT]', '[LOCATION]'); - - list_apis_sample($formattedParent); -} -// [END apigeeregistry_v1_generated_Registry_ListApis_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_artifacts.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_artifacts.php deleted file mode 100644 index 8c9c865df27f..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_artifacts.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $registryClient->listArtifacts($request); - - /** @var Artifact $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 = RegistryClient::locationName('[PROJECT]', '[LOCATION]'); - - list_artifacts_sample($formattedParent); -} -// [END apigeeregistry_v1_generated_Registry_ListArtifacts_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_locations.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_locations.php deleted file mode 100644 index 8031d0a2fe21..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_ListLocations_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/replace_artifact.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/replace_artifact.php deleted file mode 100644 index 2b489d5ff22b..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/replace_artifact.php +++ /dev/null @@ -1,59 +0,0 @@ -setArtifact($artifact); - - // Call the API and handle any network failures. - try { - /** @var Artifact $response */ - $response = $registryClient->replaceArtifact($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_ReplaceArtifact_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_deployment.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_deployment.php deleted file mode 100644 index 121259b20436..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_deployment.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName) - ->setRevisionId($revisionId); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->rollbackApiDeployment($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 = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - $revisionId = '[REVISION_ID]'; - - rollback_api_deployment_sample($formattedName, $revisionId); -} -// [END apigeeregistry_v1_generated_Registry_RollbackApiDeployment_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_spec.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_spec.php deleted file mode 100644 index 0c8eb9d5b3b1..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/rollback_api_spec.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName) - ->setRevisionId($revisionId); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->rollbackApiSpec($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - $revisionId = '[REVISION_ID]'; - - rollback_api_spec_sample($formattedName, $revisionId); -} -// [END apigeeregistry_v1_generated_Registry_RollbackApiSpec_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/set_iam_policy.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/set_iam_policy.php deleted file mode 100644 index f50b9ae496a8..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $registryClient->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); -} -// [END apigeeregistry_v1_generated_Registry_SetIamPolicy_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_deployment_revision.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_deployment_revision.php deleted file mode 100644 index ff0aa873cc91..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_deployment_revision.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName) - ->setTag($tag); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->tagApiDeploymentRevision($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 = RegistryClient::apiDeploymentName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[DEPLOYMENT]' - ); - $tag = '[TAG]'; - - tag_api_deployment_revision_sample($formattedName, $tag); -} -// [END apigeeregistry_v1_generated_Registry_TagApiDeploymentRevision_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_spec_revision.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_spec_revision.php deleted file mode 100644 index 9342e0a6f397..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/tag_api_spec_revision.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName) - ->setTag($tag); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->tagApiSpecRevision($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 = RegistryClient::apiSpecName( - '[PROJECT]', - '[LOCATION]', - '[API]', - '[VERSION]', - '[SPEC]' - ); - $tag = '[TAG]'; - - tag_api_spec_revision_sample($formattedName, $tag); -} -// [END apigeeregistry_v1_generated_Registry_TagApiSpecRevision_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/test_iam_permissions.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/test_iam_permissions.php deleted file mode 100644 index 8d4b3d05aa18..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $registryClient->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); -} -// [END apigeeregistry_v1_generated_Registry_TestIamPermissions_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api.php deleted file mode 100644 index eaae8d242b0b..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api.php +++ /dev/null @@ -1,59 +0,0 @@ -setApi($api); - - // Call the API and handle any network failures. - try { - /** @var Api $response */ - $response = $registryClient->updateApi($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_UpdateApi_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_deployment.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_deployment.php deleted file mode 100644 index 97a716950432..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_deployment.php +++ /dev/null @@ -1,59 +0,0 @@ -setApiDeployment($apiDeployment); - - // Call the API and handle any network failures. - try { - /** @var ApiDeployment $response */ - $response = $registryClient->updateApiDeployment($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_UpdateApiDeployment_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_spec.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_spec.php deleted file mode 100644 index a908ccd919e9..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_spec.php +++ /dev/null @@ -1,59 +0,0 @@ -setApiSpec($apiSpec); - - // Call the API and handle any network failures. - try { - /** @var ApiSpec $response */ - $response = $registryClient->updateApiSpec($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_UpdateApiSpec_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_version.php b/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_version.php deleted file mode 100644 index d12f35d41071..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/samples/V1/RegistryClient/update_api_version.php +++ /dev/null @@ -1,59 +0,0 @@ -setApiVersion($apiVersion); - - // Call the API and handle any network failures. - try { - /** @var ApiVersion $response */ - $response = $registryClient->updateApiVersion($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END apigeeregistry_v1_generated_Registry_UpdateApiVersion_sync] diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/ProvisioningGapicClient.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/ProvisioningGapicClient.php deleted file mode 100644 index c1c05333fbcb..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/ProvisioningGapicClient.php +++ /dev/null @@ -1,803 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $instanceId = 'instance_id'; - * $instance = new Instance(); - * $operationResponse = $provisioningClient->createInstance($formattedParent, $instanceId, $instance); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $provisioningClient->createInstance($formattedParent, $instanceId, $instance); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $provisioningClient->resumeOperation($operationName, 'createInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * 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. - */ -class ProvisioningGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.apigeeregistry.v1.Provisioning'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'apigeeregistry.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $instanceNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/provisioning_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/provisioning_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/provisioning_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/provisioning_rest_client_config.php', - ], - ], - ]; - } - - private static function getInstanceNameTemplate() - { - if (self::$instanceNameTemplate == null) { - self::$instanceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/instances/{instance}'); - } - - return self::$instanceNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'instance' => self::getInstanceNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a instance - * resource. - * - * @param string $project - * @param string $location - * @param string $instance - * - * @return string The formatted instance resource. - */ - public static function instanceName($project, $location, $instance) - { - return self::getInstanceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'instance' => $instance, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - instance: projects/{project}/locations/{location}/instances/{instance} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'apigeeregistry.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Provisions instance resources for the Registry. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $formattedParent = $provisioningClient->locationName('[PROJECT]', '[LOCATION]'); - * $instanceId = 'instance_id'; - * $instance = new Instance(); - * $operationResponse = $provisioningClient->createInstance($formattedParent, $instanceId, $instance); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $provisioningClient->createInstance($formattedParent, $instanceId, $instance); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $provisioningClient->resumeOperation($operationName, 'createInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent resource of the Instance, of the form: `projects/*/locations/*` - * @param string $instanceId Required. Identifier to assign to the Instance. Must be unique within scope of the - * parent resource. - * @param Instance $instance Required. The Instance. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createInstance($parent, $instanceId, $instance, array $optionalArgs = []) - { - $request = new CreateInstanceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setInstanceId($instanceId); - $request->setInstance($instance); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes the Registry instance. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $formattedName = $provisioningClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $provisioningClient->deleteInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $provisioningClient->deleteInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $provisioningClient->resumeOperation($operationName, 'deleteInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Instance to delete. - * Format: `projects/*/locations/*/instances/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteInstance($name, array $optionalArgs = []) - { - $request = new DeleteInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single Instance. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $formattedName = $provisioningClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $response = $provisioningClient->getInstance($formattedName); - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Instance to retrieve. - * Format: `projects/*/locations/*/instances/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Instance - * - * @throws ApiException if the remote call fails - */ - public function getInstance($name, array $optionalArgs = []) - { - $request = new GetInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetInstance', Instance::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $response = $provisioningClient->getLocation(); - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $provisioningClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $provisioningClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $resource = 'resource'; - * $response = $provisioningClient->getIamPolicy($resource); - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $provisioningClient->setIamPolicy($resource, $policy); - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $provisioningClient = new ProvisioningClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $provisioningClient->testIamPermissions($resource, $permissions); - * } finally { - * $provisioningClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/RegistryGapicClient.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/RegistryGapicClient.php deleted file mode 100644 index ae95c61b4db2..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/Gapic/RegistryGapicClient.php +++ /dev/null @@ -1,2750 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $api = new Api(); - * $apiId = 'api_id'; - * $response = $registryClient->createApi($formattedParent, $api, $apiId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * 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. - */ -class RegistryGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.apigeeregistry.v1.Registry'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'apigeeregistry.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $apiNameTemplate; - - private static $apiDeploymentNameTemplate; - - private static $apiSpecNameTemplate; - - private static $apiVersionNameTemplate; - - private static $artifactNameTemplate; - - private static $locationNameTemplate; - - private static $projectLocationApiArtifactNameTemplate; - - private static $projectLocationApiDeploymentArtifactNameTemplate; - - private static $projectLocationApiVersionArtifactNameTemplate; - - private static $projectLocationApiVersionSpecArtifactNameTemplate; - - private static $projectLocationArtifactNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/registry_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/registry_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/registry_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/registry_rest_client_config.php', - ], - ], - ]; - } - - private static function getApiNameTemplate() - { - if (self::$apiNameTemplate == null) { - self::$apiNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}'); - } - - return self::$apiNameTemplate; - } - - private static function getApiDeploymentNameTemplate() - { - if (self::$apiDeploymentNameTemplate == null) { - self::$apiDeploymentNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}'); - } - - return self::$apiDeploymentNameTemplate; - } - - private static function getApiSpecNameTemplate() - { - if (self::$apiSpecNameTemplate == null) { - self::$apiSpecNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}'); - } - - return self::$apiSpecNameTemplate; - } - - private static function getApiVersionNameTemplate() - { - if (self::$apiVersionNameTemplate == null) { - self::$apiVersionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/versions/{version}'); - } - - return self::$apiVersionNameTemplate; - } - - private static function getArtifactNameTemplate() - { - if (self::$artifactNameTemplate == null) { - self::$artifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/artifacts/{artifact}'); - } - - return self::$artifactNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getProjectLocationApiArtifactNameTemplate() - { - if (self::$projectLocationApiArtifactNameTemplate == null) { - self::$projectLocationApiArtifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/artifacts/{artifact}'); - } - - return self::$projectLocationApiArtifactNameTemplate; - } - - private static function getProjectLocationApiDeploymentArtifactNameTemplate() - { - if (self::$projectLocationApiDeploymentArtifactNameTemplate == null) { - self::$projectLocationApiDeploymentArtifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}/artifacts/{artifact}'); - } - - return self::$projectLocationApiDeploymentArtifactNameTemplate; - } - - private static function getProjectLocationApiVersionArtifactNameTemplate() - { - if (self::$projectLocationApiVersionArtifactNameTemplate == null) { - self::$projectLocationApiVersionArtifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/versions/{version}/artifacts/{artifact}'); - } - - return self::$projectLocationApiVersionArtifactNameTemplate; - } - - private static function getProjectLocationApiVersionSpecArtifactNameTemplate() - { - if (self::$projectLocationApiVersionSpecArtifactNameTemplate == null) { - self::$projectLocationApiVersionSpecArtifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}/artifacts/{artifact}'); - } - - return self::$projectLocationApiVersionSpecArtifactNameTemplate; - } - - private static function getProjectLocationArtifactNameTemplate() - { - if (self::$projectLocationArtifactNameTemplate == null) { - self::$projectLocationArtifactNameTemplate = new PathTemplate('projects/{project}/locations/{location}/artifacts/{artifact}'); - } - - return self::$projectLocationArtifactNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'api' => self::getApiNameTemplate(), - 'apiDeployment' => self::getApiDeploymentNameTemplate(), - 'apiSpec' => self::getApiSpecNameTemplate(), - 'apiVersion' => self::getApiVersionNameTemplate(), - 'artifact' => self::getArtifactNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'projectLocationApiArtifact' => self::getProjectLocationApiArtifactNameTemplate(), - 'projectLocationApiDeploymentArtifact' => self::getProjectLocationApiDeploymentArtifactNameTemplate(), - 'projectLocationApiVersionArtifact' => self::getProjectLocationApiVersionArtifactNameTemplate(), - 'projectLocationApiVersionSpecArtifact' => self::getProjectLocationApiVersionSpecArtifactNameTemplate(), - 'projectLocationArtifact' => self::getProjectLocationArtifactNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a api - * resource. - * - * @param string $project - * @param string $location - * @param string $api - * - * @return string The formatted api resource. - */ - public static function apiName($project, $location, $api) - { - return self::getApiNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * api_deployment resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $deployment - * - * @return string The formatted api_deployment resource. - */ - public static function apiDeploymentName($project, $location, $api, $deployment) - { - return self::getApiDeploymentNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'deployment' => $deployment, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a api_spec - * resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $version - * @param string $spec - * - * @return string The formatted api_spec resource. - */ - public static function apiSpecName($project, $location, $api, $version, $spec) - { - return self::getApiSpecNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'version' => $version, - 'spec' => $spec, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a api_version - * resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $version - * - * @return string The formatted api_version resource. - */ - public static function apiVersionName($project, $location, $api, $version) - { - return self::getApiVersionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'version' => $version, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a artifact - * resource. - * - * @param string $project - * @param string $location - * @param string $artifact - * - * @return string The formatted artifact resource. - */ - public static function artifactName($project, $location, $artifact) - { - return self::getArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'artifact' => $artifact, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_api_artifact resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $artifact - * - * @return string The formatted project_location_api_artifact resource. - */ - public static function projectLocationApiArtifactName($project, $location, $api, $artifact) - { - return self::getProjectLocationApiArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'artifact' => $artifact, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_api_deployment_artifact resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $deployment - * @param string $artifact - * - * @return string The formatted project_location_api_deployment_artifact resource. - */ - public static function projectLocationApiDeploymentArtifactName($project, $location, $api, $deployment, $artifact) - { - return self::getProjectLocationApiDeploymentArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'deployment' => $deployment, - 'artifact' => $artifact, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_api_version_artifact resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $version - * @param string $artifact - * - * @return string The formatted project_location_api_version_artifact resource. - */ - public static function projectLocationApiVersionArtifactName($project, $location, $api, $version, $artifact) - { - return self::getProjectLocationApiVersionArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'version' => $version, - 'artifact' => $artifact, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_api_version_spec_artifact resource. - * - * @param string $project - * @param string $location - * @param string $api - * @param string $version - * @param string $spec - * @param string $artifact - * - * @return string The formatted project_location_api_version_spec_artifact resource. - */ - public static function projectLocationApiVersionSpecArtifactName($project, $location, $api, $version, $spec, $artifact) - { - return self::getProjectLocationApiVersionSpecArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'api' => $api, - 'version' => $version, - 'spec' => $spec, - 'artifact' => $artifact, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_artifact resource. - * - * @param string $project - * @param string $location - * @param string $artifact - * - * @return string The formatted project_location_artifact resource. - */ - public static function projectLocationArtifactName($project, $location, $artifact) - { - return self::getProjectLocationArtifactNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'artifact' => $artifact, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - api: projects/{project}/locations/{location}/apis/{api} - * - apiDeployment: projects/{project}/locations/{location}/apis/{api}/deployments/{deployment} - * - apiSpec: projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec} - * - apiVersion: projects/{project}/locations/{location}/apis/{api}/versions/{version} - * - artifact: projects/{project}/locations/{location}/artifacts/{artifact} - * - location: projects/{project}/locations/{location} - * - projectLocationApiArtifact: projects/{project}/locations/{location}/apis/{api}/artifacts/{artifact} - * - projectLocationApiDeploymentArtifact: projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}/artifacts/{artifact} - * - projectLocationApiVersionArtifact: projects/{project}/locations/{location}/apis/{api}/versions/{version}/artifacts/{artifact} - * - projectLocationApiVersionSpecArtifact: projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}/artifacts/{artifact} - * - projectLocationArtifact: projects/{project}/locations/{location}/artifacts/{artifact} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'apigeeregistry.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a specified API. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->locationName('[PROJECT]', '[LOCATION]'); - * $api = new Api(); - * $apiId = 'api_id'; - * $response = $registryClient->createApi($formattedParent, $api, $apiId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * @param Api $api Required. The API to create. - * @param string $apiId Required. The ID to use for the API, which will become the final component of - * the API's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Api - * - * @throws ApiException if the remote call fails - */ - public function createApi($parent, $api, $apiId, array $optionalArgs = []) - { - $request = new CreateApiRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setApi($api); - $request->setApiId($apiId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateApi', Api::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a specified deployment. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * $apiDeployment = new ApiDeployment(); - * $apiDeploymentId = 'api_deployment_id'; - * $response = $registryClient->createApiDeployment($formattedParent, $apiDeployment, $apiDeploymentId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * @param ApiDeployment $apiDeployment Required. The deployment to create. - * @param string $apiDeploymentId Required. The ID to use for the deployment, which will become the final component of - * the deployment's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function createApiDeployment($parent, $apiDeployment, $apiDeploymentId, array $optionalArgs = []) - { - $request = new CreateApiDeploymentRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setApiDeployment($apiDeployment); - $request->setApiDeploymentId($apiDeploymentId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateApiDeployment', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a specified spec. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - * $apiSpec = new ApiSpec(); - * $apiSpecId = 'api_spec_id'; - * $response = $registryClient->createApiSpec($formattedParent, $apiSpec, $apiSpecId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param ApiSpec $apiSpec Required. The spec to create. - * @param string $apiSpecId Required. The ID to use for the spec, which will become the final component of - * the spec's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function createApiSpec($parent, $apiSpec, $apiSpecId, array $optionalArgs = []) - { - $request = new CreateApiSpecRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setApiSpec($apiSpec); - $request->setApiSpecId($apiSpecId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateApiSpec', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a specified version. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * $apiVersion = new ApiVersion(); - * $apiVersionId = 'api_version_id'; - * $response = $registryClient->createApiVersion($formattedParent, $apiVersion, $apiVersionId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * @param ApiVersion $apiVersion Required. The version to create. - * @param string $apiVersionId Required. The ID to use for the version, which will become the final component of - * the version's resource name. - * - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiVersion - * - * @throws ApiException if the remote call fails - */ - public function createApiVersion($parent, $apiVersion, $apiVersionId, array $optionalArgs = []) - { - $request = new CreateApiVersionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setApiVersion($apiVersion); - $request->setApiVersionId($apiVersionId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateApiVersion', ApiVersion::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a specified artifact. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->locationName('[PROJECT]', '[LOCATION]'); - * $artifact = new Artifact(); - * $artifactId = 'artifact_id'; - * $response = $registryClient->createArtifact($formattedParent, $artifact, $artifactId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * @param Artifact $artifact Required. The artifact to create. - * @param string $artifactId Required. The ID to use for the artifact, which will become the final component of - * the artifact's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Following AIP-162, IDs must not have the form of a UUID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Artifact - * - * @throws ApiException if the remote call fails - */ - public function createArtifact($parent, $artifact, $artifactId, array $optionalArgs = []) - { - $request = new CreateArtifactRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setArtifact($artifact); - $request->setArtifactId($artifactId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateArtifact', Artifact::class, $optionalArgs, $request)->wait(); - } - - /** - * Removes a specified API and all of the resources that it - * owns. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * $registryClient->deleteApi($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the API to delete. - * Format: `projects/*/locations/*/apis/*` - * @param array $optionalArgs { - * Optional. - * - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteApi($name, array $optionalArgs = []) - { - $request = new DeleteApiRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['force'])) { - $request->setForce($optionalArgs['force']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApi', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Removes a specified deployment, all revisions, and all - * child resources (e.g., artifacts). - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * $registryClient->deleteApiDeployment($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the deployment to delete. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @param array $optionalArgs { - * Optional. - * - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteApiDeployment($name, array $optionalArgs = []) - { - $request = new DeleteApiDeploymentRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['force'])) { - $request->setForce($optionalArgs['force']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApiDeployment', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a revision of a deployment. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * $response = $registryClient->deleteApiDeploymentRevision($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the deployment revision to be deleted, - * with a revision ID explicitly included. - * - * Example: - * `projects/sample/locations/global/apis/petstore/deployments/prod@c7cfa2a8` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function deleteApiDeploymentRevision($name, array $optionalArgs = []) - { - $request = new DeleteApiDeploymentRevisionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApiDeploymentRevision', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Removes a specified spec, all revisions, and all child - * resources (e.g., artifacts). - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $registryClient->deleteApiSpec($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec to delete. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @param array $optionalArgs { - * Optional. - * - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteApiSpec($name, array $optionalArgs = []) - { - $request = new DeleteApiSpecRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['force'])) { - $request->setForce($optionalArgs['force']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApiSpec', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a revision of a spec. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $response = $registryClient->deleteApiSpecRevision($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec revision to be deleted, - * with a revision ID explicitly included. - * - * Example: - * `projects/sample/locations/global/apis/petstore/versions/1.0.0/specs/openapi.yaml@c7cfa2a8` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function deleteApiSpecRevision($name, array $optionalArgs = []) - { - $request = new DeleteApiSpecRevisionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApiSpecRevision', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Removes a specified version and all of the resources that - * it owns. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - * $registryClient->deleteApiVersion($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the version to delete. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param array $optionalArgs { - * Optional. - * - * @type bool $force - * If set to true, any child resources will also be deleted. - * (Otherwise, the request will only work if there are no child resources.) - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteApiVersion($name, array $optionalArgs = []) - { - $request = new DeleteApiVersionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['force'])) { - $request->setForce($optionalArgs['force']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteApiVersion', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Removes a specified artifact. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - * $registryClient->deleteArtifact($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the artifact to delete. - * Format: `{parent}/artifacts/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteArtifact($name, array $optionalArgs = []) - { - $request = new DeleteArtifactRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteArtifact', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a specified API. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * $response = $registryClient->getApi($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the API to retrieve. - * Format: `projects/*/locations/*/apis/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Api - * - * @throws ApiException if the remote call fails - */ - public function getApi($name, array $optionalArgs = []) - { - $request = new GetApiRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetApi', Api::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a specified deployment. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * $response = $registryClient->getApiDeployment($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the deployment to retrieve. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function getApiDeployment($name, array $optionalArgs = []) - { - $request = new GetApiDeploymentRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetApiDeployment', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a specified spec. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $response = $registryClient->getApiSpec($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function getApiSpec($name, array $optionalArgs = []) - { - $request = new GetApiSpecRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetApiSpec', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the contents of a specified spec. - * If specs are stored with GZip compression, the default behavior - * is to return the spec uncompressed (the mime_type response field - * indicates the exact format returned). - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $response = $registryClient->getApiSpecContents($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec whose contents should be retrieved. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Api\HttpBody - * - * @throws ApiException if the remote call fails - */ - public function getApiSpecContents($name, array $optionalArgs = []) - { - $request = new GetApiSpecContentsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetApiSpecContents', HttpBody::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a specified version. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - * $response = $registryClient->getApiVersion($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the version to retrieve. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiVersion - * - * @throws ApiException if the remote call fails - */ - public function getApiVersion($name, array $optionalArgs = []) - { - $request = new GetApiVersionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetApiVersion', ApiVersion::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a specified artifact. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - * $response = $registryClient->getArtifact($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the artifact to retrieve. - * Format: `{parent}/artifacts/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Artifact - * - * @throws ApiException if the remote call fails - */ - public function getArtifact($name, array $optionalArgs = []) - { - $request = new GetArtifactRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetArtifact', Artifact::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the contents of a specified artifact. - * If artifacts are stored with GZip compression, the default behavior - * is to return the artifact uncompressed (the mime_type response field - * indicates the exact format returned). - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - * $response = $registryClient->getArtifactContents($formattedName); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the artifact whose contents should be retrieved. - * Format: `{parent}/artifacts/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Api\HttpBody - * - * @throws ApiException if the remote call fails - */ - public function getArtifactContents($name, array $optionalArgs = []) - { - $request = new GetArtifactContentsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetArtifactContents', HttpBody::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists all revisions of a deployment. - * Revisions are returned in descending order of revision creation time. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApiDeploymentRevisions($formattedName); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApiDeploymentRevisions($formattedName); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the deployment to list revisions for. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApiDeploymentRevisions($name, array $optionalArgs = []) - { - $request = new ListApiDeploymentRevisionsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApiDeploymentRevisions', $optionalArgs, ListApiDeploymentRevisionsResponse::class, $request); - } - - /** - * Returns matching deployments. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApiDeployments($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApiDeployments($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of deployments. - * Format: `projects/*/locations/*/apis/*` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApiDeployments($parent, array $optionalArgs = []) - { - $request = new ListApiDeploymentsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApiDeployments', $optionalArgs, ListApiDeploymentsResponse::class, $request); - } - - /** - * Lists all revisions of a spec. - * Revisions are returned in descending order of revision creation time. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApiSpecRevisions($formattedName); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApiSpecRevisions($formattedName); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec to list revisions for. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApiSpecRevisions($name, array $optionalArgs = []) - { - $request = new ListApiSpecRevisionsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApiSpecRevisions', $optionalArgs, ListApiSpecRevisionsResponse::class, $request); - } - - /** - * Returns matching specs. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApiSpecs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApiSpecs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of specs. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApiSpecs($parent, array $optionalArgs = []) - { - $request = new ListApiSpecsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApiSpecs', $optionalArgs, ListApiSpecsResponse::class, $request); - } - - /** - * Returns matching versions. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApiVersions($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApiVersions($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of versions. - * Format: `projects/*/locations/*/apis/*` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApiVersions($parent, array $optionalArgs = []) - { - $request = new ListApiVersionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApiVersions', $optionalArgs, ListApiVersionsResponse::class, $request); - } - - /** - * Returns matching APIs. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listApis($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listApis($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of APIs. - * Format: `projects/*/locations/*` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listApis($parent, array $optionalArgs = []) - { - $request = new ListApisRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListApis', $optionalArgs, ListApisResponse::class, $request); - } - - /** - * Returns matching artifacts. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedParent = $registryClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listArtifacts($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listArtifacts($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of artifacts. - * Format: `{parent}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * An expression that can be used to filter the list. Filters use the Common - * Expression Language and can refer to all message fields except contents. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listArtifacts($parent, array $optionalArgs = []) - { - $request = new ListArtifactsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListArtifacts', $optionalArgs, ListArtifactsResponse::class, $request); - } - - /** - * Used to replace a specified artifact. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $artifact = new Artifact(); - * $response = $registryClient->replaceArtifact($artifact); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param Artifact $artifact Required. The artifact to replace. - * - * The `name` field is used to identify the artifact to replace. - * Format: `{parent}/artifacts/*` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Artifact - * - * @throws ApiException if the remote call fails - */ - public function replaceArtifact($artifact, array $optionalArgs = []) - { - $request = new ReplaceArtifactRequest(); - $requestParamHeaders = []; - $request->setArtifact($artifact); - $requestParamHeaders['artifact.name'] = $artifact->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('ReplaceArtifact', Artifact::class, $optionalArgs, $request)->wait(); - } - - /** - * Sets the current revision to a specified prior - * revision. Note that this creates a new revision with a new revision ID. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * $revisionId = 'revision_id'; - * $response = $registryClient->rollbackApiDeployment($formattedName, $revisionId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The deployment being rolled back. - * @param string $revisionId Required. The revision ID to roll back to. - * It must be a revision of the same deployment. - * - * Example: `c7cfa2a8` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function rollbackApiDeployment($name, $revisionId, array $optionalArgs = []) - { - $request = new RollbackApiDeploymentRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setRevisionId($revisionId); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RollbackApiDeployment', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Sets the current revision to a specified prior revision. - * Note that this creates a new revision with a new revision ID. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $revisionId = 'revision_id'; - * $response = $registryClient->rollbackApiSpec($formattedName, $revisionId); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The spec being rolled back. - * @param string $revisionId Required. The revision ID to roll back to. - * It must be a revision of the same spec. - * - * Example: `c7cfa2a8` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function rollbackApiSpec($name, $revisionId, array $optionalArgs = []) - { - $request = new RollbackApiSpecRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setRevisionId($revisionId); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RollbackApiSpec', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Adds a tag to a specified revision of a - * deployment. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - * $tag = 'tag'; - * $response = $registryClient->tagApiDeploymentRevision($formattedName, $tag); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the deployment to be tagged, including the revision ID. - * @param string $tag Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function tagApiDeploymentRevision($name, $tag, array $optionalArgs = []) - { - $request = new TagApiDeploymentRevisionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setTag($tag); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TagApiDeploymentRevision', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Adds a tag to a specified revision of a spec. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $formattedName = $registryClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - * $tag = 'tag'; - * $response = $registryClient->tagApiSpecRevision($formattedName, $tag); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the spec to be tagged, including the revision ID. - * @param string $tag Required. The tag to apply. - * The tag should be at most 40 characters, and match `[a-z][a-z0-9-]{3,39}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function tagApiSpecRevision($name, $tag, array $optionalArgs = []) - { - $request = new TagApiSpecRevisionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setTag($tag); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TagApiSpecRevision', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Used to modify a specified API. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $api = new Api(); - * $response = $registryClient->updateApi($api); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param Api $api Required. The API to update. - * - * The `name` field is used to identify the API to update. - * Format: `projects/*/locations/*/apis/*` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allowMissing - * If set to true, and the API is not found, a new API will be created. - * In this situation, `update_mask` is ignored. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\Api - * - * @throws ApiException if the remote call fails - */ - public function updateApi($api, array $optionalArgs = []) - { - $request = new UpdateApiRequest(); - $requestParamHeaders = []; - $request->setApi($api); - $requestParamHeaders['api.name'] = $api->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateApi', Api::class, $optionalArgs, $request)->wait(); - } - - /** - * Used to modify a specified deployment. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $apiDeployment = new ApiDeployment(); - * $response = $registryClient->updateApiDeployment($apiDeployment); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param ApiDeployment $apiDeployment Required. The deployment to update. - * - * The `name` field is used to identify the deployment to update. - * Format: `projects/*/locations/*/apis/*/deployments/*` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allowMissing - * If set to true, and the deployment is not found, a new deployment will be - * created. In this situation, `update_mask` is ignored. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiDeployment - * - * @throws ApiException if the remote call fails - */ - public function updateApiDeployment($apiDeployment, array $optionalArgs = []) - { - $request = new UpdateApiDeploymentRequest(); - $requestParamHeaders = []; - $request->setApiDeployment($apiDeployment); - $requestParamHeaders['api_deployment.name'] = $apiDeployment->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateApiDeployment', ApiDeployment::class, $optionalArgs, $request)->wait(); - } - - /** - * Used to modify a specified spec. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $apiSpec = new ApiSpec(); - * $response = $registryClient->updateApiSpec($apiSpec); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param ApiSpec $apiSpec Required. The spec to update. - * - * The `name` field is used to identify the spec to update. - * Format: `projects/*/locations/*/apis/*/versions/*/specs/*` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allowMissing - * If set to true, and the spec is not found, a new spec will be created. - * In this situation, `update_mask` is ignored. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiSpec - * - * @throws ApiException if the remote call fails - */ - public function updateApiSpec($apiSpec, array $optionalArgs = []) - { - $request = new UpdateApiSpecRequest(); - $requestParamHeaders = []; - $request->setApiSpec($apiSpec); - $requestParamHeaders['api_spec.name'] = $apiSpec->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateApiSpec', ApiSpec::class, $optionalArgs, $request)->wait(); - } - - /** - * Used to modify a specified version. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $apiVersion = new ApiVersion(); - * $response = $registryClient->updateApiVersion($apiVersion); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param ApiVersion $apiVersion Required. The version to update. - * - * The `name` field is used to identify the version to update. - * Format: `projects/*/locations/*/apis/*/versions/*` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. If omitted, all fields are updated that - * are set in the request message (fields set to default values are ignored). - * If an asterisk "*" is specified, all fields are updated, including fields - * that are unspecified/default in the request. - * @type bool $allowMissing - * If set to true, and the version is not found, a new version will be - * created. In this situation, `update_mask` is ignored. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ApigeeRegistry\V1\ApiVersion - * - * @throws ApiException if the remote call fails - */ - public function updateApiVersion($apiVersion, array $optionalArgs = []) - { - $request = new UpdateApiVersionRequest(); - $requestParamHeaders = []; - $request->setApiVersion($apiVersion); - $requestParamHeaders['api_version.name'] = $apiVersion->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateApiVersion', ApiVersion::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $response = $registryClient->getLocation(); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $registryClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $registryClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $resource = 'resource'; - * $response = $registryClient->getIamPolicy($resource); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $registryClient->setIamPolicy($resource, $policy); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $registryClient = new RegistryClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $registryClient->testIamPermissions($resource, $permissions); - * } finally { - * $registryClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/ProvisioningClient.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/ProvisioningClient.php deleted file mode 100644 index bd80b5ed3343..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/ProvisioningClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.cloud.apigeeregistry.v1.Provisioning' => [ - 'CreateInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ApigeeRegistry\V1\Instance', - 'metadataReturnType' => '\Google\Cloud\ApigeeRegistry\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\ApigeeRegistry\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetInstance' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Instance', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_rest_client_config.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_rest_client_config.php deleted file mode 100644 index 4c802901d908..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/provisioning_rest_client_config.php +++ /dev/null @@ -1,286 +0,0 @@ - [ - 'google.cloud.apigeeregistry.v1.Provisioning' => [ - 'CreateInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/instances', - 'body' => 'instance', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'instance_id', - ], - ], - 'DeleteInstance' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/instances/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetInstance' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/instances/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_client_config.json b/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_client_config.json deleted file mode 100644 index c24d2f4e969d..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_client_config.json +++ /dev/null @@ -1,247 +0,0 @@ -{ - "interfaces": { - "google.cloud.apigeeregistry.v1.Registry": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "ABORTED", - "CANCELLED", - "DEADLINE_EXCEEDED", - "UNAVAILABLE" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 200, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateApi": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateApiDeployment": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateApiSpec": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateApiVersion": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateArtifact": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApi": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApiDeployment": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApiDeploymentRevision": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApiSpec": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApiSpecRevision": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteApiVersion": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteArtifact": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetApi": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetApiDeployment": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetApiSpec": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetApiSpecContents": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetApiVersion": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetArtifact": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetArtifactContents": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApiDeploymentRevisions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApiDeployments": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApiSpecRevisions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApiSpecs": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApiVersions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListApis": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListArtifacts": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ReplaceArtifact": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RollbackApiDeployment": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "RollbackApiSpec": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "TagApiDeploymentRevision": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "TagApiSpecRevision": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateApi": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateApiDeployment": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateApiSpec": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateApiVersion": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_descriptor_config.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_descriptor_config.php deleted file mode 100644 index 7d53a500a7e2..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_descriptor_config.php +++ /dev/null @@ -1,575 +0,0 @@ - [ - 'google.cloud.apigeeregistry.v1.Registry' => [ - 'CreateApi' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateApiDeployment' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateApiSpec' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateApiVersion' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateArtifact' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteApi' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiDeployment' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiDeploymentRevision' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiSpec' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiSpecRevision' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiVersion' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteArtifact' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetApi' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetApiDeployment' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetApiSpec' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetApiSpecContents' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Api\HttpBody', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetApiVersion' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetArtifact' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetArtifactContents' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Api\HttpBody', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListApiDeploymentRevisions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApiDeployments', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentRevisionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListApiDeployments' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApiDeployments', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiDeploymentsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListApiSpecRevisions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApiSpecs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiSpecRevisionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListApiSpecs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApiSpecs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiSpecsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListApiVersions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApiVersions', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApiVersionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListApis' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getApis', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListApisResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListArtifacts' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getArtifacts', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ListArtifactsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ReplaceArtifact' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Artifact', - 'headerParams' => [ - [ - 'keyName' => 'artifact.name', - 'fieldAccessors' => [ - 'getArtifact', - 'getName', - ], - ], - ], - ], - 'RollbackApiDeployment' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RollbackApiSpec' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'TagApiDeploymentRevision' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'TagApiSpecRevision' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateApi' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\Api', - 'headerParams' => [ - [ - 'keyName' => 'api.name', - 'fieldAccessors' => [ - 'getApi', - 'getName', - ], - ], - ], - ], - 'UpdateApiDeployment' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiDeployment', - 'headerParams' => [ - [ - 'keyName' => 'api_deployment.name', - 'fieldAccessors' => [ - 'getApiDeployment', - 'getName', - ], - ], - ], - ], - 'UpdateApiSpec' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiSpec', - 'headerParams' => [ - [ - 'keyName' => 'api_spec.name', - 'fieldAccessors' => [ - 'getApiSpec', - 'getName', - ], - ], - ], - ], - 'UpdateApiVersion' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ApigeeRegistry\V1\ApiVersion', - 'headerParams' => [ - [ - 'keyName' => 'api_version.name', - 'fieldAccessors' => [ - 'getApiVersion', - 'getName', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'api' => 'projects/{project}/locations/{location}/apis/{api}', - 'apiDeployment' => 'projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}', - 'apiSpec' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}', - 'apiVersion' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}', - 'artifact' => 'projects/{project}/locations/{location}/artifacts/{artifact}', - 'location' => 'projects/{project}/locations/{location}', - 'projectLocationApiArtifact' => 'projects/{project}/locations/{location}/apis/{api}/artifacts/{artifact}', - 'projectLocationApiDeploymentArtifact' => 'projects/{project}/locations/{location}/apis/{api}/deployments/{deployment}/artifacts/{artifact}', - 'projectLocationApiVersionArtifact' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/artifacts/{artifact}', - 'projectLocationApiVersionSpecArtifact' => 'projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}/artifacts/{artifact}', - 'projectLocationArtifact' => 'projects/{project}/locations/{location}/artifacts/{artifact}', - ], - ], - ], -]; diff --git a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_rest_client_config.php b/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_rest_client_config.php deleted file mode 100644 index a9f49918eb33..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/src/V1/resources/registry_rest_client_config.php +++ /dev/null @@ -1,796 +0,0 @@ - [ - 'google.cloud.apigeeregistry.v1.Registry' => [ - 'CreateApi' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/apis', - 'body' => 'api', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'api_id', - ], - ], - 'CreateApiDeployment' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/deployments', - 'body' => 'api_deployment', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'api_deployment_id', - ], - ], - 'CreateApiSpec' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*}/specs', - 'body' => 'api_spec', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'api_spec_id', - ], - ], - 'CreateApiVersion' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/versions', - 'body' => 'api_version', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'api_version_id', - ], - ], - 'CreateArtifact' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/artifacts', - 'body' => 'artifact', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/artifacts', - 'body' => 'artifact', - 'queryParams' => [ - 'artifact_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*}/artifacts', - 'body' => 'artifact', - 'queryParams' => [ - 'artifact_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*/specs/*}/artifacts', - 'body' => 'artifact', - 'queryParams' => [ - 'artifact_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/deployments/*}/artifacts', - 'body' => 'artifact', - 'queryParams' => [ - 'artifact_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'artifact_id', - ], - ], - 'DeleteApi' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiDeployment' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiDeploymentRevision' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}:deleteRevision', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiSpec' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiSpecRevision' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:deleteRevision', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteApiVersion' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteArtifact' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/artifacts/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/artifacts/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetApi' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetApiDeployment' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetApiSpec' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetApiSpecContents' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:getContents', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetApiVersion' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetArtifact' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/artifacts/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/artifacts/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetArtifactContents' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/artifacts/*}:getContents', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/artifacts/*}:getContents', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/artifacts/*}:getContents', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:getContents', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}:getContents', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListApiDeploymentRevisions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}:listRevisions', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListApiDeployments' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/deployments', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListApiSpecRevisions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:listRevisions', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListApiSpecs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*}/specs', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListApiVersions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/versions', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListApis' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/apis', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListArtifacts' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/artifacts', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*}/artifacts', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*}/artifacts', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/versions/*/specs/*}/artifacts', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/apis/*/deployments/*}/artifacts', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ReplaceArtifact' => [ - 'method' => 'put', - 'uriTemplate' => '/v1/{artifact.name=projects/*/locations/*/artifacts/*}', - 'body' => 'artifact', - 'additionalBindings' => [ - [ - 'method' => 'put', - 'uriTemplate' => '/v1/{artifact.name=projects/*/locations/*/apis/*/artifacts/*}', - 'body' => 'artifact', - ], - [ - 'method' => 'put', - 'uriTemplate' => '/v1/{artifact.name=projects/*/locations/*/apis/*/versions/*/artifacts/*}', - 'body' => 'artifact', - ], - [ - 'method' => 'put', - 'uriTemplate' => '/v1/{artifact.name=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}', - 'body' => 'artifact', - ], - [ - 'method' => 'put', - 'uriTemplate' => '/v1/{artifact.name=projects/*/locations/*/apis/*/deployments/*/artifacts/*}', - 'body' => 'artifact', - ], - ], - 'placeholders' => [ - 'artifact.name' => [ - 'getters' => [ - 'getArtifact', - 'getName', - ], - ], - ], - ], - 'RollbackApiDeployment' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}:rollback', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'RollbackApiSpec' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:rollback', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'TagApiDeploymentRevision' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/deployments/*}:tagRevision', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'TagApiSpecRevision' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:tagRevision', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateApi' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{api.name=projects/*/locations/*/apis/*}', - 'body' => 'api', - 'placeholders' => [ - 'api.name' => [ - 'getters' => [ - 'getApi', - 'getName', - ], - ], - ], - ], - 'UpdateApiDeployment' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{api_deployment.name=projects/*/locations/*/apis/*/deployments/*}', - 'body' => 'api_deployment', - 'placeholders' => [ - 'api_deployment.name' => [ - 'getters' => [ - 'getApiDeployment', - 'getName', - ], - ], - ], - ], - 'UpdateApiSpec' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{api_spec.name=projects/*/locations/*/apis/*/versions/*/specs/*}', - 'body' => 'api_spec', - 'placeholders' => [ - 'api_spec.name' => [ - 'getters' => [ - 'getApiSpec', - 'getName', - ], - ], - ], - ], - 'UpdateApiVersion' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{api_version.name=projects/*/locations/*/apis/*/versions/*}', - 'body' => 'api_version', - 'placeholders' => [ - 'api_version.name' => [ - 'getters' => [ - 'getApiVersion', - 'getName', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/deployments/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/apis/*/versions/*/specs/*/artifacts/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/runtime}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/ProvisioningClientTest.php b/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/ProvisioningClientTest.php deleted file mode 100644 index d90668a27bc1..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/ProvisioningClientTest.php +++ /dev/null @@ -1,697 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ProvisioningClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ProvisioningClient($options); - } - - /** @test */ - public function createInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $stateMessage = 'stateMessage29641305'; - $expectedResponse = new Instance(); - $expectedResponse->setName($name); - $expectedResponse->setStateMessage($stateMessage); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $instanceId = 'instanceId-2101995259'; - $instance = new Instance(); - $instanceConfig = new Config(); - $configCmekKeyName = 'configCmekKeyName-1633313736'; - $instanceConfig->setCmekKeyName($configCmekKeyName); - $instance->setConfig($instanceConfig); - $response = $gapicClient->createInstance($formattedParent, $instanceId, $instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Provisioning/CreateInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getInstanceId(); - $this->assertProtobufEquals($instanceId, $actualValue); - $actualValue = $actualApiRequestObject->getInstance(); - $this->assertProtobufEquals($instance, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $instanceId = 'instanceId-2101995259'; - $instance = new Instance(); - $instanceConfig = new Config(); - $configCmekKeyName = 'configCmekKeyName-1633313736'; - $instanceConfig->setCmekKeyName($configCmekKeyName); - $instance->setConfig($instanceConfig); - $response = $gapicClient->createInstance($formattedParent, $instanceId, $instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->deleteInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Provisioning/DeleteInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->deleteInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getInstanceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $stateMessage = 'stateMessage29641305'; - $expectedResponse = new Instance(); - $expectedResponse->setName($name2); - $expectedResponse->setStateMessage($stateMessage); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->getInstance($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Provisioning/GetInstance', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getInstanceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - try { - $gapicClient->getInstance($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/RegistryClientTest.php b/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/RegistryClientTest.php deleted file mode 100644 index f733bd7bb285..000000000000 --- a/owl-bot-staging/ApigeeRegistry/v1/tests/Unit/V1/RegistryClientTest.php +++ /dev/null @@ -1,2853 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return RegistryClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new RegistryClient($options); - } - - /** @test */ - public function createApiTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $availability = 'availability1997542747'; - $recommendedVersion = 'recommendedVersion265230068'; - $recommendedDeployment = 'recommendedDeployment1339243305'; - $expectedResponse = new Api(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setAvailability($availability); - $expectedResponse->setRecommendedVersion($recommendedVersion); - $expectedResponse->setRecommendedDeployment($recommendedDeployment); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $api = new Api(); - $apiId = 'apiId-1411282592'; - $response = $gapicClient->createApi($formattedParent, $api, $apiId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/CreateApi', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getApi(); - $this->assertProtobufEquals($api, $actualValue); - $actualValue = $actualRequestObject->getApiId(); - $this->assertProtobufEquals($apiId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $api = new Api(); - $apiId = 'apiId-1411282592'; - try { - $gapicClient->createApi($formattedParent, $api, $apiId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiDeploymentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiDeployment = new ApiDeployment(); - $apiDeploymentId = 'apiDeploymentId-276259984'; - $response = $gapicClient->createApiDeployment($formattedParent, $apiDeployment, $apiDeploymentId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/CreateApiDeployment', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getApiDeployment(); - $this->assertProtobufEquals($apiDeployment, $actualValue); - $actualValue = $actualRequestObject->getApiDeploymentId(); - $this->assertProtobufEquals($apiDeploymentId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiDeploymentExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiDeployment = new ApiDeployment(); - $apiDeploymentId = 'apiDeploymentId-276259984'; - try { - $gapicClient->createApiDeployment($formattedParent, $apiDeployment, $apiDeploymentId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiSpecTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $apiSpec = new ApiSpec(); - $apiSpecId = 'apiSpecId800293626'; - $response = $gapicClient->createApiSpec($formattedParent, $apiSpec, $apiSpecId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/CreateApiSpec', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getApiSpec(); - $this->assertProtobufEquals($apiSpec, $actualValue); - $actualValue = $actualRequestObject->getApiSpecId(); - $this->assertProtobufEquals($apiSpecId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiSpecExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $apiSpec = new ApiSpec(); - $apiSpecId = 'apiSpecId800293626'; - try { - $gapicClient->createApiSpec($formattedParent, $apiSpec, $apiSpecId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiVersionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $state = 'state109757585'; - $expectedResponse = new ApiVersion(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setState($state); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiVersion = new ApiVersion(); - $apiVersionId = 'apiVersionId790654247'; - $response = $gapicClient->createApiVersion($formattedParent, $apiVersion, $apiVersionId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/CreateApiVersion', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getApiVersion(); - $this->assertProtobufEquals($apiVersion, $actualValue); - $actualValue = $actualRequestObject->getApiVersionId(); - $this->assertProtobufEquals($apiVersionId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createApiVersionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $apiVersion = new ApiVersion(); - $apiVersionId = 'apiVersionId790654247'; - try { - $gapicClient->createApiVersion($formattedParent, $apiVersion, $apiVersionId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createArtifactTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $contents = '26'; - $expectedResponse = new Artifact(); - $expectedResponse->setName($name); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $artifact = new Artifact(); - $artifactId = 'artifactId-1130052952'; - $response = $gapicClient->createArtifact($formattedParent, $artifact, $artifactId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/CreateArtifact', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getArtifact(); - $this->assertProtobufEquals($artifact, $actualValue); - $actualValue = $actualRequestObject->getArtifactId(); - $this->assertProtobufEquals($artifactId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createArtifactExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $artifact = new Artifact(); - $artifactId = 'artifactId-1130052952'; - try { - $gapicClient->createArtifact($formattedParent, $artifact, $artifactId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $gapicClient->deleteApi($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApi', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - try { - $gapicClient->deleteApi($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiDeploymentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $gapicClient->deleteApiDeployment($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApiDeployment', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiDeploymentExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - try { - $gapicClient->deleteApiDeployment($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiDeploymentRevisionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $response = $gapicClient->deleteApiDeploymentRevision($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApiDeploymentRevision', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiDeploymentRevisionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - try { - $gapicClient->deleteApiDeploymentRevision($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiSpecTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $gapicClient->deleteApiSpec($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApiSpec', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiSpecExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - try { - $gapicClient->deleteApiSpec($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiSpecRevisionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name2); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $response = $gapicClient->deleteApiSpecRevision($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApiSpecRevision', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiSpecRevisionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - try { - $gapicClient->deleteApiSpecRevision($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiVersionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $gapicClient->deleteApiVersion($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteApiVersion', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteApiVersionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - try { - $gapicClient->deleteApiVersion($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteArtifactTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - $gapicClient->deleteArtifact($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/DeleteArtifact', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteArtifactExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - try { - $gapicClient->deleteArtifact($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $availability = 'availability1997542747'; - $recommendedVersion = 'recommendedVersion265230068'; - $recommendedDeployment = 'recommendedDeployment1339243305'; - $expectedResponse = new Api(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setAvailability($availability); - $expectedResponse->setRecommendedVersion($recommendedVersion); - $expectedResponse->setRecommendedDeployment($recommendedDeployment); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $response = $gapicClient->getApi($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetApi', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - try { - $gapicClient->getApi($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiDeploymentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $response = $gapicClient->getApiDeployment($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetApiDeployment', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiDeploymentExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - try { - $gapicClient->getApiDeployment($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiSpecTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name2); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $response = $gapicClient->getApiSpec($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetApiSpec', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiSpecExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - try { - $gapicClient->getApiSpec($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiSpecContentsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $contentType = 'contentType831846208'; - $data = '-86'; - $expectedResponse = new HttpBody(); - $expectedResponse->setContentType($contentType); - $expectedResponse->setData($data); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $response = $gapicClient->getApiSpecContents($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetApiSpecContents', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiSpecContentsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - try { - $gapicClient->getApiSpecContents($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiVersionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $state = 'state109757585'; - $expectedResponse = new ApiVersion(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setState($state); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $response = $gapicClient->getApiVersion($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetApiVersion', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getApiVersionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - try { - $gapicClient->getApiVersion($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getArtifactTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $contents = '26'; - $expectedResponse = new Artifact(); - $expectedResponse->setName($name2); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - $response = $gapicClient->getArtifact($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetArtifact', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getArtifactExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - try { - $gapicClient->getArtifact($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getArtifactContentsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $contentType = 'contentType831846208'; - $data = '-86'; - $expectedResponse = new HttpBody(); - $expectedResponse->setContentType($contentType); - $expectedResponse->setData($data); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - $response = $gapicClient->getArtifactContents($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/GetArtifactContents', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getArtifactContentsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->artifactName('[PROJECT]', '[LOCATION]', '[ARTIFACT]'); - try { - $gapicClient->getArtifactContents($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiDeploymentRevisionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apiDeploymentsElement = new ApiDeployment(); - $apiDeployments = [ - $apiDeploymentsElement, - ]; - $expectedResponse = new ListApiDeploymentRevisionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApiDeployments($apiDeployments); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $response = $gapicClient->listApiDeploymentRevisions($formattedName); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApiDeployments()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApiDeploymentRevisions', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiDeploymentRevisionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - try { - $gapicClient->listApiDeploymentRevisions($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiDeploymentsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apiDeploymentsElement = new ApiDeployment(); - $apiDeployments = [ - $apiDeploymentsElement, - ]; - $expectedResponse = new ListApiDeploymentsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApiDeployments($apiDeployments); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $response = $gapicClient->listApiDeployments($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApiDeployments()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApiDeployments', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiDeploymentsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - try { - $gapicClient->listApiDeployments($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiSpecRevisionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apiSpecsElement = new ApiSpec(); - $apiSpecs = [ - $apiSpecsElement, - ]; - $expectedResponse = new ListApiSpecRevisionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApiSpecs($apiSpecs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $response = $gapicClient->listApiSpecRevisions($formattedName); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApiSpecs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApiSpecRevisions', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiSpecRevisionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - try { - $gapicClient->listApiSpecRevisions($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiSpecsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apiSpecsElement = new ApiSpec(); - $apiSpecs = [ - $apiSpecsElement, - ]; - $expectedResponse = new ListApiSpecsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApiSpecs($apiSpecs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - $response = $gapicClient->listApiSpecs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApiSpecs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApiSpecs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiSpecsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiVersionName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]'); - try { - $gapicClient->listApiSpecs($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiVersionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apiVersionsElement = new ApiVersion(); - $apiVersions = [ - $apiVersionsElement, - ]; - $expectedResponse = new ListApiVersionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApiVersions($apiVersions); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - $response = $gapicClient->listApiVersions($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApiVersions()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApiVersions', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApiVersionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->apiName('[PROJECT]', '[LOCATION]', '[API]'); - try { - $gapicClient->listApiVersions($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApisTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $apisElement = new Api(); - $apis = [ - $apisElement, - ]; - $expectedResponse = new ListApisResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setApis($apis); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listApis($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getApis()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListApis', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listApisExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listApis($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listArtifactsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $artifactsElement = new Artifact(); - $artifacts = [ - $artifactsElement, - ]; - $expectedResponse = new ListArtifactsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setArtifacts($artifacts); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listArtifacts($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getArtifacts()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ListArtifacts', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listArtifactsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listArtifacts($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function replaceArtifactTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $contents = '26'; - $expectedResponse = new Artifact(); - $expectedResponse->setName($name); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $artifact = new Artifact(); - $response = $gapicClient->replaceArtifact($artifact); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/ReplaceArtifact', $actualFuncCall); - $actualValue = $actualRequestObject->getArtifact(); - $this->assertProtobufEquals($artifact, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function replaceArtifactExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $artifact = new Artifact(); - try { - $gapicClient->replaceArtifact($artifact); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function rollbackApiDeploymentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId2 = 'revisionId2-100208654'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId2); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $revisionId = 'revisionId513861631'; - $response = $gapicClient->rollbackApiDeployment($formattedName, $revisionId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/RollbackApiDeployment', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getRevisionId(); - $this->assertProtobufEquals($revisionId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function rollbackApiDeploymentExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $revisionId = 'revisionId513861631'; - try { - $gapicClient->rollbackApiDeployment($formattedName, $revisionId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function rollbackApiSpecTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId2 = 'revisionId2-100208654'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name2); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId2); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $revisionId = 'revisionId513861631'; - $response = $gapicClient->rollbackApiSpec($formattedName, $revisionId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/RollbackApiSpec', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getRevisionId(); - $this->assertProtobufEquals($revisionId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function rollbackApiSpecExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $revisionId = 'revisionId513861631'; - try { - $gapicClient->rollbackApiSpec($formattedName, $revisionId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function tagApiDeploymentRevisionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $tag = 'tag114586'; - $response = $gapicClient->tagApiDeploymentRevision($formattedName, $tag); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/TagApiDeploymentRevision', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getTag(); - $this->assertProtobufEquals($tag, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function tagApiDeploymentRevisionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiDeploymentName('[PROJECT]', '[LOCATION]', '[API]', '[DEPLOYMENT]'); - $tag = 'tag114586'; - try { - $gapicClient->tagApiDeploymentRevision($formattedName, $tag); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function tagApiSpecRevisionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name2); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $tag = 'tag114586'; - $response = $gapicClient->tagApiSpecRevision($formattedName, $tag); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/TagApiSpecRevision', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getTag(); - $this->assertProtobufEquals($tag, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function tagApiSpecRevisionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->apiSpecName('[PROJECT]', '[LOCATION]', '[API]', '[VERSION]', '[SPEC]'); - $tag = 'tag114586'; - try { - $gapicClient->tagApiSpecRevision($formattedName, $tag); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $availability = 'availability1997542747'; - $recommendedVersion = 'recommendedVersion265230068'; - $recommendedDeployment = 'recommendedDeployment1339243305'; - $expectedResponse = new Api(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setAvailability($availability); - $expectedResponse->setRecommendedVersion($recommendedVersion); - $expectedResponse->setRecommendedDeployment($recommendedDeployment); - $transport->addResponse($expectedResponse); - // Mock request - $api = new Api(); - $response = $gapicClient->updateApi($api); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/UpdateApi', $actualFuncCall); - $actualValue = $actualRequestObject->getApi(); - $this->assertProtobufEquals($api, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $api = new Api(); - try { - $gapicClient->updateApi($api); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiDeploymentTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $apiSpecRevision = 'apiSpecRevision-1685452166'; - $endpointUri = 'endpointUri-850313278'; - $externalChannelUri = 'externalChannelUri-559177284'; - $intendedAudience = 'intendedAudience-1100067944'; - $accessGuidance = 'accessGuidance24590291'; - $expectedResponse = new ApiDeployment(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setApiSpecRevision($apiSpecRevision); - $expectedResponse->setEndpointUri($endpointUri); - $expectedResponse->setExternalChannelUri($externalChannelUri); - $expectedResponse->setIntendedAudience($intendedAudience); - $expectedResponse->setAccessGuidance($accessGuidance); - $transport->addResponse($expectedResponse); - // Mock request - $apiDeployment = new ApiDeployment(); - $response = $gapicClient->updateApiDeployment($apiDeployment); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/UpdateApiDeployment', $actualFuncCall); - $actualValue = $actualRequestObject->getApiDeployment(); - $this->assertProtobufEquals($apiDeployment, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiDeploymentExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $apiDeployment = new ApiDeployment(); - try { - $gapicClient->updateApiDeployment($apiDeployment); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiSpecTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $filename = 'filename-734768633'; - $description = 'description-1724546052'; - $revisionId = 'revisionId513861631'; - $mimeType = 'mimeType-196041627'; - $sizeBytes = 1796325715; - $hash = 'hash3195150'; - $sourceUri = 'sourceUri-1111107768'; - $contents = '26'; - $expectedResponse = new ApiSpec(); - $expectedResponse->setName($name); - $expectedResponse->setFilename($filename); - $expectedResponse->setDescription($description); - $expectedResponse->setRevisionId($revisionId); - $expectedResponse->setMimeType($mimeType); - $expectedResponse->setSizeBytes($sizeBytes); - $expectedResponse->setHash($hash); - $expectedResponse->setSourceUri($sourceUri); - $expectedResponse->setContents($contents); - $transport->addResponse($expectedResponse); - // Mock request - $apiSpec = new ApiSpec(); - $response = $gapicClient->updateApiSpec($apiSpec); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/UpdateApiSpec', $actualFuncCall); - $actualValue = $actualRequestObject->getApiSpec(); - $this->assertProtobufEquals($apiSpec, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiSpecExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $apiSpec = new ApiSpec(); - try { - $gapicClient->updateApiSpec($apiSpec); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiVersionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $state = 'state109757585'; - $expectedResponse = new ApiVersion(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setState($state); - $transport->addResponse($expectedResponse); - // Mock request - $apiVersion = new ApiVersion(); - $response = $gapicClient->updateApiVersion($apiVersion); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.apigeeregistry.v1.Registry/UpdateApiVersion', $actualFuncCall); - $actualValue = $actualRequestObject->getApiVersion(); - $this->assertProtobufEquals($apiVersion, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateApiVersionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $apiVersion = new ApiVersion(); - try { - $gapicClient->updateApiVersion($apiVersion); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Baremetalsolution.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Baremetalsolution.php deleted file mode 100644 index 365c6bd16e74..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Baremetalsolution.php +++ /dev/null @@ -1,77 +0,0 @@ -internalAddGeneratedFile( - ' -Ý( -9google/cloud/baremetalsolution/v2/baremetalsolution.proto!google.cloud.baremetalsolution.v2google/api/client.protogoogle/api/field_behavior.proto0google/cloud/baremetalsolution/v2/instance.proto+google/cloud/baremetalsolution/v2/lun.proto/google/cloud/baremetalsolution/v2/network.proto1google/cloud/baremetalsolution/v2/nfs_share.proto.google/cloud/baremetalsolution/v2/volume.proto#google/longrunning/operations.protogoogle/protobuf/timestamp.proto"€ -OperationMetadata4 - create_time ( 2.google.protobuf.TimestampBàA1 -end_time ( 2.google.protobuf.TimestampBàA -target ( BàA -verb ( BàA -status_message ( BàA# -requested_cancellation (BàA - api_version ( BàA" -ResetInstanceResponse2Ý -BareMetalSolution - ListInstances7.google.cloud.baremetalsolution.v2.ListInstancesRequest8.google.cloud.baremetalsolution.v2.ListInstancesResponse">‚Óä“/-/v2/{parent=projects/*/locations/*}/instancesÚAparent¯ - GetInstance5.google.cloud.baremetalsolution.v2.GetInstanceRequest+.google.cloud.baremetalsolution.v2.Instance"<‚Óä“/-/v2/{name=projects/*/locations/*/instances/*}ÚAnameê -UpdateInstance8.google.cloud.baremetalsolution.v2.UpdateInstanceRequest.google.longrunning.Operation"‚Óä“B26/v2/{instance.name=projects/*/locations/*/instances/*}:instanceÚAinstance,update_maskÊA -InstanceOperationMetadataÛ - ResetInstance7.google.cloud.baremetalsolution.v2.ResetInstanceRequest.google.longrunning.Operation"r‚Óä“8"3/v2/{name=projects/*/locations/*/instances/*}:reset:*ÚAnameÊA* -ResetInstanceResponseOperationMetadataÛ - StartInstance7.google.cloud.baremetalsolution.v2.StartInstanceRequest.google.longrunning.Operation"r‚Óä“8"3/v2/{name=projects/*/locations/*/instances/*}:start:*ÚAnameÊA* -StartInstanceResponseOperationMetadata× - StopInstance6.google.cloud.baremetalsolution.v2.StopInstanceRequest.google.longrunning.Operation"p‚Óä“7"2/v2/{name=projects/*/locations/*/instances/*}:stop:*ÚAnameÊA) -StopInstanceResponseOperationMetadataÖ - DetachLun3.google.cloud.baremetalsolution.v2.DetachLunRequest.google.longrunning.Operation"u‚Óä“@";/v2/{instance=projects/*/locations/*/instances/*}:detachLun:*ÚA instance,lunÊA -InstanceOperationMetadataº - ListVolumes5.google.cloud.baremetalsolution.v2.ListVolumesRequest6.google.cloud.baremetalsolution.v2.ListVolumesResponse"<‚Óä“-+/v2/{parent=projects/*/locations/*}/volumesÚAparent§ - GetVolume3.google.cloud.baremetalsolution.v2.GetVolumeRequest).google.cloud.baremetalsolution.v2.Volume":‚Óä“-+/v2/{name=projects/*/locations/*/volumes/*}ÚAnameÜ - UpdateVolume6.google.cloud.baremetalsolution.v2.UpdateVolumeRequest.google.longrunning.Operation"u‚Óä“<22/v2/{volume.name=projects/*/locations/*/volumes/*}:volumeÚAvolume,update_maskÊA -VolumeOperationMetadataÖ - ResizeVolume6.google.cloud.baremetalsolution.v2.ResizeVolumeRequest.google.longrunning.Operation"o‚Óä“9"4/v2/{volume=projects/*/locations/*/volumes/*}:resize:*ÚAvolume,size_gibÊA -VolumeOperationMetadata¾ - ListNetworks6.google.cloud.baremetalsolution.v2.ListNetworksRequest7.google.cloud.baremetalsolution.v2.ListNetworksResponse"=‚Óä“.,/v2/{parent=projects/*/locations/*}/networksÚAparentß -ListNetworkUsage:.google.cloud.baremetalsolution.v2.ListNetworkUsageRequest;.google.cloud.baremetalsolution.v2.ListNetworkUsageResponse"R‚Óä“A?/v2/{location=projects/*/locations/*}/networks:listNetworkUsageÚAlocation« - -GetNetwork4.google.cloud.baremetalsolution.v2.GetNetworkRequest*.google.cloud.baremetalsolution.v2.Network";‚Óä“.,/v2/{name=projects/*/locations/*/networks/*}ÚAnameã - UpdateNetwork7.google.cloud.baremetalsolution.v2.UpdateNetworkRequest.google.longrunning.Operation"z‚Óä“?24/v2/{network.name=projects/*/locations/*/networks/*}:networkÚAnetwork,update_maskÊA -NetworkOperationMetadata¥ -GetLun0.google.cloud.baremetalsolution.v2.GetLunRequest&.google.cloud.baremetalsolution.v2.Lun"A‚Óä“42/v2/{name=projects/*/locations/*/volumes/*/luns/*}ÚAname¸ -ListLuns2.google.cloud.baremetalsolution.v2.ListLunsRequest3.google.cloud.baremetalsolution.v2.ListLunsResponse"C‚Óä“42/v2/{parent=projects/*/locations/*/volumes/*}/lunsÚAparent¯ - GetNfsShare5.google.cloud.baremetalsolution.v2.GetNfsShareRequest+.google.cloud.baremetalsolution.v2.NfsShare"<‚Óä“/-/v2/{name=projects/*/locations/*/nfsShares/*}ÚAname - ListNfsShares7.google.cloud.baremetalsolution.v2.ListNfsSharesRequest8.google.cloud.baremetalsolution.v2.ListNfsSharesResponse">‚Óä“/-/v2/{parent=projects/*/locations/*}/nfsSharesÚAparentî -UpdateNfsShare8.google.cloud.baremetalsolution.v2.UpdateNfsShareRequest.google.longrunning.Operation"‚‚Óä“D27/v2/{nfs_share.name=projects/*/locations/*/nfsShares/*}: nfs_shareÚAnfs_share,update_maskÊA -NfsShareOperationMetadataTÊA baremetalsolution.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformB… -%com.google.cloud.baremetalsolution.v2BBareMetalSolutionProtoPZScloud.google.com/go/baremetalsolution/apiv2/baremetalsolutionpb;baremetalsolutionpbª!Google.Cloud.BareMetalSolution.V2Ê!Google\\Cloud\\BareMetalSolution\\V2ê$Google::Cloud::BareMetalSolution::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Instance.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Instance.php deleted file mode 100644 index a2ddee31e31bc6fe07337a1e8b0cdc8c6ddaea8c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3954 zcmcIn+j1I55DlOUG_s7>H>?L|g%w-!Wr=Yru~)tX1fodEKnWyOQdCjPGQh^m?q+vT zqNsRGRUYz^ROKgE~nte;ti7km@z9N<@b+M2y)tAxKF$cCvWU*_S zU7e&=-5j*jEyX5%LKWRH^#RpPBfXzVYlcG=LnRUi2QZXAaV$k8VzHWgj=S3mRT@Q( z)7W4*joc_sV>h!7pz4a_h$RmX4nf3!)}W`VzRv}mWgqABKn?HS!ggUjgmo$Z76ypPaM_OENa?S+$zgm zLW6*^mDM%xSO%wc#8uZvSsrupiAe1MIeNM%+Jp{lW1aiW0EWS@#)PPs5xt!w zJ!M}rZCQSMtG6I0nQjv=pHo|%oT$duz?lB@f59me`mJfdm>w%g5s$=k#d#Oox`yRR zmA*CkTwWIUo@!nZWZUf^=bOls)gVhOXSd+btMKtzDIzSp77{0wG)5|EKeKer163?7 zZF|Xc3AS|S^z-zA;cZTzzS(fo;2HRY=VV4Yq&uwYntcqmx8p+(GT1@=h`Jk6zt2O| zC$Vq=W|$x(Lt&gv2@^cA(I8EAH3k>m{b;B%N|yd}w5{9Mf3_s>2#Ig)=lsm2V2>u{xq zcsA|fP1>5#Z4yIi>7<>UL&&I5ggISl5#347ixIruXJOR_1NOJiqRPDXzQa8guPuwoCUQel+xPh`b;NZWRmXV0K^8 z2X48>I;~4i{Ua{sMWLeLUX5Fs}?p&o25cN@qv(lh3a-?w^S=t%B6BK5fb7s zzr9oDA7S>9FKiX+xHlr}ud*7fof-(g3WdkW#IK1;o%EsiYnawe75gP-DShbw90r{l z7d5ZR4pTcI6bbdgw#hdGlteA16;Mq05;b2CBgupyCM?2SN7J#1y9`hL z5Q57it~eHkh6qm~<_E$-cNjVEOi?U;u!O5{-XP!6<`EZ|g2jZ3C{PBff!bq2fPO_* zW2v9ej~y;sK7b#S97KITcvQ~j1|wEjNC%q8wE9FP4O(Yv4=&-e;D1Ox0wWjfAocz& z-@B%E;bM)N)@bzJ8~2wGB=Y!BRePwHzPB4AIf>=Y&H~{PL{PDLGGe*AywY#N%Bj>w zH&TDhz~#wWH=(62!!^aS@SV)c4HXbO8oqaVn{)7VtUiHER7h5t@l0uoqMzuCG^U$> zV=PA(g@vPPf}YIq{>!McnA!W!&c?osq-W|~$99a88?{l*G#eW+6NYFi2j`A&xeiOE za=oyt9w!RXYkZxk@>YYCR8;a%m$GmVXVs%KjXB=RUPJtyW{B9dC2#LwC73 z+Cqn^t5_|^N#|-@>I!4yQPQ~Uxi=yB2>a>j(a&Mf+q%3X89 zY={DmA w#f6e(jwQ=uV6wcMY0Y6SsQKVl@T9-%j%i1xI=nYdof9THzSEt%hA;&92Z_-m2LJ#7 diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Lun.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Lun.php deleted file mode 100644 index c9edb2d8eb52286a52a59fdb3a91fc24a02c1ffd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2083 zcmb7F-EQJm5H5cSOwtW;Rh3p%bwaZnqRkqK_M&o{t^gAjl>~&Hs9RY=#vH(1$9C;w zw&{wizD*ycw|#-V-WRB}SDkYVgk7>qmK%=8Gv9nO{^rb&PyLAx-;ySEX<#xsB!g?h zCY1Pr$2`k($RHYxXh1CQ%C{XF$b_gJa^BHNLv87M7#ey}U{QsPJ#XyLvgLTuuskpW zdPSM(gq{;I+jGm)O4*5AS>OV=<`oTn)1su=t(~Fc&}6336c9$8Lm0L9A&kq)F@WWm zVMyAM3$K9S&yNO2H625xp%vIZ^MWqAD$1C$WgEGrbU07T;p`D9#T*r7 zjpPYoK}1)x6B1As1@5un%>ic1lW|MSs=jTU+SD1==)|1bUZ5y9Ro#GmD6~iCU-8x` z(TXQO+4I7y!{M^dQ`AIh$&B+nfWNlj@kfY3+KZiKp&WTlIr6mf)t7TT)3?jPoNFwl z;=dV4p&F!JNOMsY5+qT|)l#pkDG4BH4-3Ez(lKOs`)MJGj}IzG@|{U#M3prjBkjOu zh;r(W2Za=drz9PutH@#YVoLh#+NXuIfd1j0&}XXvI>t*XJP1)u=9u=UI5t>JhI6kS zy{#UCaj@Q*xCU%WDC2yVFGUb`A{S0@c+7!A3mb@#mGY1scpmHH1Qs@ha9OqipAQSiObJ*4Ns@~{doNL`iy>;4ZsQFK%ZOGPpjjG-{ zZ{`#H>7uK~Pe~~U8GNNa&!_kcwb5<}w{)=vyX)O5!Z&9ZZN1g)b@WcX)9&lfyYFX1 z#CGfa;+K4)cmi9itiOhWrgwVPX5+TFO-N~)iUjfSOjYwq#eGwK0sD7;0uU0C z_0jzp6|Z5ZZHF8!T);hr4Iee)viZQ21>i@@%;!?&lOd)mBjLme6Z2kBSBy%oIEDO8 z?$E~;Q0aR}^HMQ&s diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Network.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/Network.php deleted file mode 100644 index 90a28bf992e9957371ae2a1e107eed88d54a4852..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3517 zcmbtX&2ke*5RN3vwpzl71%l9NEl4mFtSC{Wk~M}%SavBfwj#-@N=m7%(e6mzc)h#q z&I%mLmt0bLhP(lfk{8G!7tU0kAi1Px_QyXm6}j-m(rEhY?ytY@nR)We-E-lVyh&~9 z5k?Jpcqp?yD!ZP;9Nn?xVK5p|Pu86S*R-go$nyG*yuH(to9nIKGMf5M;OSJA$Br|$ zXjQkIz^D$1M-M0?mhV^rGab7+sa0*tUOC>rBCr8$azK5T=v3ZpH(uaogD^7K6flG5 z9A?ls3p41~RsnR2_`bXy!oeGm@y`v0mZ{4=BMkrDHhs;sO=c3y{28-alSdc}Mce7U zqrldAh%z_Wv30s~R}L}x-rKH&EUd|KU~Ntek}_!7jCwY)2J6(V}bUw1K)>NwVTO-hscaL-m4! zl9odQMJQ02QlK)am2XCv#5Jp4lxrx*a;#q=PONWr#A(zHFr#os=@En(QSnRh5%hf6;7CZ#Oo-8j4%a*wl$7&bJXB z&yoXWD_qkeb>P{Gp81bF56;oIGjMbkScw)QnH@WfwGry)23$_up<{!-7Wrn&Z&PsN zLlDSU6lXcqE83qSA#co0LVV zcIeB1`b>IyvI!aw-__Iq)bGvS-<4leaCOV{V_2MNA?{Z&@8Z?TW?}M;y8`(ZEXN)1 zN99T;##S^HxUO6>rkaoUCLy&fKaRu_bM~nnYE4>#`H^X%2uhrrT;-P(Tss|!@8Wc( z(i2#WsEnm@Zw9GEJV{u4o4#h+3IAc~aMA>}N3m1M(BiWNkHgAu7{soN*GPJX=dVwz zAz!;d4E%IYOI7qIkj0Ha5Rr*|G4nNMO^$d?!@EIOZF>fEfsx@Nv+WfxV zPW{jg_r^CVJmkjCInN9fG`=*Z4oG*ndd}M0^zx>7ZYbipp){~(_(R0%Mz0p7U;888 zGl KOZ*WW0sIGme_pZx diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/NfsShare.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/GPBMetadata/Google/Cloud/Baremetalsolution/V2/NfsShare.php deleted file mode 100644 index cd1cd1ec66752b678a012d8c38615e5f9fb68960..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2573 zcmb7GT~8ZF6s>JAaNQW#Car^7X>h18O;`)}q0ItGZ7`N4ur1pVsj{?Mug7@9dUvxk z>y#qDR(+}Z*q>0TKc&AS&-n?c51pC);KLwdURaIqJ#+4vGk5OJYiHoVGgQGAb~TE7 zsC$m+03*k>sjb^4>U#Y?c9Cum9mB+~jL?1^)#`0j-mkV-St_wTSH}uEwe3?A=XKNe zdik#A;vuG*No>=jhHd3Xg}l`#DjBd}WPuJ~X+umLO~^ozo<_A!MF4g7I8di_ z8>n+q*apx|jSy7plNQH=3qb78@w%p=BSJOG{;e5AH7tV~nrZyX3fo0}MhCOx$=JSU z>6|6v33W@yxeerF^4K-UWV+ikE=MLESZQk1Xc zHiB(AoY6-)pQEBoklaPo_3-uG5pps0Tx(nK<^bd9t8<5LMaSqI7})HU@IV_GwyP*t zRb7GHm)gX^fqrsUB!}4bNF!%=?_YNm3IQHPf`;)2M10sY@7j~wp>WG6ht}vKQ7R0t{509AQ zvD~~Q0r*SAVq=e{J;BbXg&ric9k zmH3abY#wHPw>*L6R=e0PtH-rgqr6u=sFwGaK9d$9)o9jFs;z3h#uj4PIxJ04UWIRt z>c_RV+9)@Vsx2Pdx`i_jGtF|50Z3^8{-wTYR@>#JxH9}$d7pVL80bZ=>wUAMPb zrzC$7e2w#_t+Ou9P9T2~evbJAA~M)wbjilqV~{GChF7JD-+7o&>Gh4fx%HtKzbrnV zf>rkS7(6~SNCZqm8oB#c(G$+9_5Edy&ME&2lG* zC2F5xD{x{Ol6}KuZ;OA=v%kgQ$t^0xVcK9;B}7UP#)seL=Tn$f`U(~;{0s9ur{!}H zElc_WQl8~vO&@4ollQDdZXx>zBXaDpR~p}zdk+>OB0`txc<|;Km-1{+fi60(5GYkx z3CjtavK+lLrT=2^Eo*RL#Qjab^e80U;E#7B_H)Y*4tp@`lBf0^V+%V&Hn~iA+39ZI zvGz}VwIYTWSqv|7iP?mYHD)WAg5;CJzhO)#m~h01b0ez5W}J`lH6Kb*1eT&qfGNsJ fp_>${e7_z&o-h0X;@Z4%@2nvr{fS@vFrVWUGbh{JLxBCdQ<0|_kG@v^SmG5zVOB#YzR%_5Z?&NKlUdZ3{6bmEH7Q%)zdZ`qiOn!Ibn`PDp&muzLy#OyBZC*YBXHB#lToOC~+p+D^<; zIBO_u#Xd^XH79q4(2vMP>w@5uF!G%p<~IeH&c1p#WKH(0-hoBzL4%BqiRJo|G>>Wy za+~TgN#63#TC;R8tFMgU^k$1JjnDS1Bx&+sFw4;avTAD<6^-#J{QVHb#puMZ$MPbh zpLmUa;-p@Alt3DuRr8ZjV=`7!@-k}T^VWtmi~1P`6iZb9EkHhI9RCpRQSO#ALT0Pb z;NHm`50JG6;|>4di@b`%=7u(D!Y3O zYep2h`p9>Gapsr#^b+gdK+-uQofS8;x5O^T@HlV`FBrR_j`=741dG*m^a0ksWtW#x zs94`$Ai@L;X`5mx42nO6&t{gGvjbw2km&uSEXoD6wOUsewVE5> zr7ES5_$A;pO(|vQ$4f;iWveRWG+HS9$M8_=%H69PE3mwOtjgWiQ4`e)ki#F!n^Km? z3q?It*#%dfLM2V?4Nv_HwzVUTTjlUDoqikB3+rOAy$^f`mi zxY9mURIRHYw2rkdn#PkO^@sThCk@}rCiI?OZ(nii!p;?lIEiaXCwh+k>L+4`LG5kw zHLcmM$;t}P($8r!dGTn%hUT>TJ(QXxjA4%B2Ep%M>T9)ka`uC~eRprFe`J6^w1NaR zNMXN$yoYlf*%dd;Z3esn>#2J|QiikW4wDeD(-u71M``0qxQVTn9fj^GaTpT|{3_&! zmW}h6HMTSTV@V$pPdBfCfL z4f`Xq16RmvmErYwZaDiZyWV7rq{tRYv4I4nE2ga_>!^5A|0k8{CEF%jH!n%`aNm5N s-Hf3miD607H84p!srU0N{a-zutukN6>)eIy@7B$aNyhux6s7?G0c+K}-T(jq diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/BareMetalSolutionGrpcClient.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/BareMetalSolutionGrpcClient.php deleted file mode 100644 index 421c8591b23d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/BareMetalSolutionGrpcClient.php +++ /dev/null @@ -1,344 +0,0 @@ -_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListInstances', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListInstancesResponse', 'decode'], - $metadata, $options); - } - - /** - * Get details about a single server. - * @param \Google\Cloud\BareMetalSolution\V2\GetInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetInstance(\Google\Cloud\BareMetalSolution\V2\GetInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetInstance', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\Instance', 'decode'], - $metadata, $options); - } - - /** - * Update details of a single server. - * @param \Google\Cloud\BareMetalSolution\V2\UpdateInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateInstance(\Google\Cloud\BareMetalSolution\V2\UpdateInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Perform an ungraceful, hard reset on a server. Equivalent to shutting the - * power off and then turning it back on. - * @param \Google\Cloud\BareMetalSolution\V2\ResetInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ResetInstance(\Google\Cloud\BareMetalSolution\V2\ResetInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ResetInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Starts a server that was shutdown. - * @param \Google\Cloud\BareMetalSolution\V2\StartInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function StartInstance(\Google\Cloud\BareMetalSolution\V2\StartInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/StartInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Stop a running server. - * @param \Google\Cloud\BareMetalSolution\V2\StopInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function StopInstance(\Google\Cloud\BareMetalSolution\V2\StopInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/StopInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Detach LUN from Instance. - * @param \Google\Cloud\BareMetalSolution\V2\DetachLunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DetachLun(\Google\Cloud\BareMetalSolution\V2\DetachLunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/DetachLun', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * List storage volumes in a given project and location. - * @param \Google\Cloud\BareMetalSolution\V2\ListVolumesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListVolumes(\Google\Cloud\BareMetalSolution\V2\ListVolumesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListVolumes', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListVolumesResponse', 'decode'], - $metadata, $options); - } - - /** - * Get details of a single storage volume. - * @param \Google\Cloud\BareMetalSolution\V2\GetVolumeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetVolume(\Google\Cloud\BareMetalSolution\V2\GetVolumeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetVolume', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\Volume', 'decode'], - $metadata, $options); - } - - /** - * Update details of a single storage volume. - * @param \Google\Cloud\BareMetalSolution\V2\UpdateVolumeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateVolume(\Google\Cloud\BareMetalSolution\V2\UpdateVolumeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateVolume', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Emergency Volume resize. - * @param \Google\Cloud\BareMetalSolution\V2\ResizeVolumeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ResizeVolume(\Google\Cloud\BareMetalSolution\V2\ResizeVolumeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ResizeVolume', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * List network in a given project and location. - * @param \Google\Cloud\BareMetalSolution\V2\ListNetworksRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListNetworks(\Google\Cloud\BareMetalSolution\V2\ListNetworksRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNetworks', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListNetworksResponse', 'decode'], - $metadata, $options); - } - - /** - * List all Networks (and used IPs for each Network) in the vendor account - * associated with the specified project. - * @param \Google\Cloud\BareMetalSolution\V2\ListNetworkUsageRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListNetworkUsage(\Google\Cloud\BareMetalSolution\V2\ListNetworkUsageRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNetworkUsage', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListNetworkUsageResponse', 'decode'], - $metadata, $options); - } - - /** - * Get details of a single network. - * @param \Google\Cloud\BareMetalSolution\V2\GetNetworkRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetNetwork(\Google\Cloud\BareMetalSolution\V2\GetNetworkRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetNetwork', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\Network', 'decode'], - $metadata, $options); - } - - /** - * Update details of a single network. - * @param \Google\Cloud\BareMetalSolution\V2\UpdateNetworkRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateNetwork(\Google\Cloud\BareMetalSolution\V2\UpdateNetworkRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateNetwork', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Get details of a single storage logical unit number(LUN). - * @param \Google\Cloud\BareMetalSolution\V2\GetLunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetLun(\Google\Cloud\BareMetalSolution\V2\GetLunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetLun', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\Lun', 'decode'], - $metadata, $options); - } - - /** - * List storage volume luns for given storage volume. - * @param \Google\Cloud\BareMetalSolution\V2\ListLunsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListLuns(\Google\Cloud\BareMetalSolution\V2\ListLunsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListLuns', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListLunsResponse', 'decode'], - $metadata, $options); - } - - /** - * Get details of a single NFS share. - * @param \Google\Cloud\BareMetalSolution\V2\GetNfsShareRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetNfsShare(\Google\Cloud\BareMetalSolution\V2\GetNfsShareRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetNfsShare', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\NfsShare', 'decode'], - $metadata, $options); - } - - /** - * List NFS shares. - * @param \Google\Cloud\BareMetalSolution\V2\ListNfsSharesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListNfsShares(\Google\Cloud\BareMetalSolution\V2\ListNfsSharesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNfsShares', - $argument, - ['\Google\Cloud\BareMetalSolution\V2\ListNfsSharesResponse', 'decode'], - $metadata, $options); - } - - /** - * Update details of a single NFS share. - * @param \Google\Cloud\BareMetalSolution\V2\UpdateNfsShareRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateNfsShare(\Google\Cloud\BareMetalSolution\V2\UpdateNfsShareRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateNfsShare', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/DetachLunRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/DetachLunRequest.php deleted file mode 100644 index a6f2a6e68db9..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/DetachLunRequest.php +++ /dev/null @@ -1,118 +0,0 @@ -google.cloud.baremetalsolution.v2.DetachLunRequest - */ -class DetachLunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the instance. - * - * Generated from protobuf field string instance = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $instance = ''; - /** - * Required. Name of the Lun to detach. - * - * Generated from protobuf field string lun = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $lun = ''; - - /** - * @param string $instance Required. Name of the instance. Please see - * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. - * @param string $lun Required. Name of the Lun to detach. Please see - * {@see BareMetalSolutionClient::lunName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\DetachLunRequest - * - * @experimental - */ - public static function build(string $instance, string $lun): self - { - return (new self()) - ->setInstance($instance) - ->setLun($lun); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $instance - * Required. Name of the instance. - * @type string $lun - * Required. Name of the Lun to detach. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the instance. - * - * Generated from protobuf field string instance = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getInstance() - { - return $this->instance; - } - - /** - * Required. Name of the instance. - * - * Generated from protobuf field string instance = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkString($var, True); - $this->instance = $var; - - return $this; - } - - /** - * Required. Name of the Lun to detach. - * - * Generated from protobuf field string lun = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getLun() - { - return $this->lun; - } - - /** - * Required. Name of the Lun to detach. - * - * Generated from protobuf field string lun = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setLun($var) - { - GPBUtil::checkString($var, True); - $this->lun = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetInstanceRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetInstanceRequest.php deleted file mode 100644 index 7a98047a6e5c..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetInstanceRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.GetInstanceRequest - */ -class GetInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\GetInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetLunRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetLunRequest.php deleted file mode 100644 index 1b3818ef6068..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetLunRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.GetLunRequest - */ -class GetLunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::lunName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\GetLunRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Lun::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNetworkRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNetworkRequest.php deleted file mode 100644 index b176df8e0052..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNetworkRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.GetNetworkRequest - */ -class GetNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::networkName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\GetNetworkRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNfsShareRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNfsShareRequest.php deleted file mode 100644 index 95048183c5a2..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetNfsShareRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.GetNfsShareRequest - */ -class GetNfsShareRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::nFSShareName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\GetNfsShareRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetVolumeRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetVolumeRequest.php deleted file mode 100644 index 16d3f54aa0b8..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/GetVolumeRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.GetVolumeRequest - */ -class GetVolumeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\GetVolumeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance.php deleted file mode 100644 index 4e8db4917d0d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance.php +++ /dev/null @@ -1,643 +0,0 @@ -google.cloud.baremetalsolution.v2.Instance - */ -class Instance extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this `Instance`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/instances/{instance}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * An identifier for the `Instance`, generated by the backend. - * - * Generated from protobuf field string id = 11; - */ - protected $id = ''; - /** - * Output only. Create a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Update a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * The server type. - * [Available server - * types](https://cloud.google.com/bare-metal/docs/bms-planning#server_configurations) - * - * Generated from protobuf field string machine_type = 4; - */ - protected $machine_type = ''; - /** - * The state of the server. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance.State state = 5; - */ - protected $state = 0; - /** - * True if you enable hyperthreading for the server, otherwise false. - * The default value is false. - * - * Generated from protobuf field bool hyperthreading_enabled = 6; - */ - protected $hyperthreading_enabled = false; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 7; - */ - private $labels; - /** - * List of LUNs associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 8; - */ - private $luns; - /** - * List of networks associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 9; - */ - private $networks; - /** - * True if the interactive serial console feature is enabled for the instance, - * false otherwise. - * The default value is false. - * - * Generated from protobuf field bool interactive_serial_console_enabled = 10; - */ - protected $interactive_serial_console_enabled = false; - /** - * The OS image currently installed on the server. - * - * Generated from protobuf field string os_image = 12; - */ - protected $os_image = ''; - /** - * Immutable. Pod name. - * Pod is an independent part of infrastructure. - * Instance can be connected to the assets (networks, volumes) allocated - * in the same pod only. - * - * Generated from protobuf field string pod = 13 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $pod = ''; - /** - * Instance network template name. For eg, bondaa-bondaa, bondab-nic, etc. - * Generally, the template name follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string network_template = 14 [(.google.api.resource_reference) = { - */ - protected $network_template = ''; - /** - * List of logical interfaces for the instance. The number of logical - * interfaces will be the same as number of hardware bond/nic on the chosen - * network template. For the non-multivlan configurations (for eg, existing - * servers) that use existing default network template (bondaa-bondaa), both - * the Instance.networks field and the Instance.logical_interfaces fields will - * be filled to ensure backward compatibility. For the others, only - * Instance.logical_interfaces will be filled. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface logical_interfaces = 15; - */ - private $logical_interfaces; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this `Instance`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/instances/{instance}` - * @type string $id - * An identifier for the `Instance`, generated by the backend. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Create a time stamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Update a time stamp. - * @type string $machine_type - * The server type. - * [Available server - * types](https://cloud.google.com/bare-metal/docs/bms-planning#server_configurations) - * @type int $state - * The state of the server. - * @type bool $hyperthreading_enabled - * True if you enable hyperthreading for the server, otherwise false. - * The default value is false. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * @type array<\Google\Cloud\BareMetalSolution\V2\Lun>|\Google\Protobuf\Internal\RepeatedField $luns - * List of LUNs associated with this server. - * @type array<\Google\Cloud\BareMetalSolution\V2\Network>|\Google\Protobuf\Internal\RepeatedField $networks - * List of networks associated with this server. - * @type bool $interactive_serial_console_enabled - * True if the interactive serial console feature is enabled for the instance, - * false otherwise. - * The default value is false. - * @type string $os_image - * The OS image currently installed on the server. - * @type string $pod - * Immutable. Pod name. - * Pod is an independent part of infrastructure. - * Instance can be connected to the assets (networks, volumes) allocated - * in the same pod only. - * @type string $network_template - * Instance network template name. For eg, bondaa-bondaa, bondab-nic, etc. - * Generally, the template name follows the syntax of - * "bond" or "nic". - * @type array<\Google\Cloud\BareMetalSolution\V2\LogicalInterface>|\Google\Protobuf\Internal\RepeatedField $logical_interfaces - * List of logical interfaces for the instance. The number of logical - * interfaces will be the same as number of hardware bond/nic on the chosen - * network template. For the non-multivlan configurations (for eg, existing - * servers) that use existing default network template (bondaa-bondaa), both - * the Instance.networks field and the Instance.logical_interfaces fields will - * be filled to ensure backward compatibility. For the others, only - * Instance.logical_interfaces will be filled. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this `Instance`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/instances/{instance}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of this `Instance`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/instances/{instance}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * An identifier for the `Instance`, generated by the backend. - * - * Generated from protobuf field string id = 11; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * An identifier for the `Instance`, generated by the backend. - * - * Generated from protobuf field string id = 11; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Output only. Create a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Create a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Update a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Update a time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * The server type. - * [Available server - * types](https://cloud.google.com/bare-metal/docs/bms-planning#server_configurations) - * - * Generated from protobuf field string machine_type = 4; - * @return string - */ - public function getMachineType() - { - return $this->machine_type; - } - - /** - * The server type. - * [Available server - * types](https://cloud.google.com/bare-metal/docs/bms-planning#server_configurations) - * - * Generated from protobuf field string machine_type = 4; - * @param string $var - * @return $this - */ - public function setMachineType($var) - { - GPBUtil::checkString($var, True); - $this->machine_type = $var; - - return $this; - } - - /** - * The state of the server. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance.State state = 5; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of the server. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance.State state = 5; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Instance\State::class); - $this->state = $var; - - return $this; - } - - /** - * True if you enable hyperthreading for the server, otherwise false. - * The default value is false. - * - * Generated from protobuf field bool hyperthreading_enabled = 6; - * @return bool - */ - public function getHyperthreadingEnabled() - { - return $this->hyperthreading_enabled; - } - - /** - * True if you enable hyperthreading for the server, otherwise false. - * The default value is false. - * - * Generated from protobuf field bool hyperthreading_enabled = 6; - * @param bool $var - * @return $this - */ - public function setHyperthreadingEnabled($var) - { - GPBUtil::checkBool($var); - $this->hyperthreading_enabled = $var; - - return $this; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * List of LUNs associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLuns() - { - return $this->luns; - } - - /** - * List of LUNs associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 8; - * @param array<\Google\Cloud\BareMetalSolution\V2\Lun>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLuns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Lun::class); - $this->luns = $arr; - - return $this; - } - - /** - * List of networks associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNetworks() - { - return $this->networks; - } - - /** - * List of networks associated with this server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 9; - * @param array<\Google\Cloud\BareMetalSolution\V2\Network>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNetworks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Network::class); - $this->networks = $arr; - - return $this; - } - - /** - * True if the interactive serial console feature is enabled for the instance, - * false otherwise. - * The default value is false. - * - * Generated from protobuf field bool interactive_serial_console_enabled = 10; - * @return bool - */ - public function getInteractiveSerialConsoleEnabled() - { - return $this->interactive_serial_console_enabled; - } - - /** - * True if the interactive serial console feature is enabled for the instance, - * false otherwise. - * The default value is false. - * - * Generated from protobuf field bool interactive_serial_console_enabled = 10; - * @param bool $var - * @return $this - */ - public function setInteractiveSerialConsoleEnabled($var) - { - GPBUtil::checkBool($var); - $this->interactive_serial_console_enabled = $var; - - return $this; - } - - /** - * The OS image currently installed on the server. - * - * Generated from protobuf field string os_image = 12; - * @return string - */ - public function getOsImage() - { - return $this->os_image; - } - - /** - * The OS image currently installed on the server. - * - * Generated from protobuf field string os_image = 12; - * @param string $var - * @return $this - */ - public function setOsImage($var) - { - GPBUtil::checkString($var, True); - $this->os_image = $var; - - return $this; - } - - /** - * Immutable. Pod name. - * Pod is an independent part of infrastructure. - * Instance can be connected to the assets (networks, volumes) allocated - * in the same pod only. - * - * Generated from protobuf field string pod = 13 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getPod() - { - return $this->pod; - } - - /** - * Immutable. Pod name. - * Pod is an independent part of infrastructure. - * Instance can be connected to the assets (networks, volumes) allocated - * in the same pod only. - * - * Generated from protobuf field string pod = 13 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setPod($var) - { - GPBUtil::checkString($var, True); - $this->pod = $var; - - return $this; - } - - /** - * Instance network template name. For eg, bondaa-bondaa, bondab-nic, etc. - * Generally, the template name follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string network_template = 14 [(.google.api.resource_reference) = { - * @return string - */ - public function getNetworkTemplate() - { - return $this->network_template; - } - - /** - * Instance network template name. For eg, bondaa-bondaa, bondab-nic, etc. - * Generally, the template name follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string network_template = 14 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setNetworkTemplate($var) - { - GPBUtil::checkString($var, True); - $this->network_template = $var; - - return $this; - } - - /** - * List of logical interfaces for the instance. The number of logical - * interfaces will be the same as number of hardware bond/nic on the chosen - * network template. For the non-multivlan configurations (for eg, existing - * servers) that use existing default network template (bondaa-bondaa), both - * the Instance.networks field and the Instance.logical_interfaces fields will - * be filled to ensure backward compatibility. For the others, only - * Instance.logical_interfaces will be filled. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface logical_interfaces = 15; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLogicalInterfaces() - { - return $this->logical_interfaces; - } - - /** - * List of logical interfaces for the instance. The number of logical - * interfaces will be the same as number of hardware bond/nic on the chosen - * network template. For the non-multivlan configurations (for eg, existing - * servers) that use existing default network template (bondaa-bondaa), both - * the Instance.networks field and the Instance.logical_interfaces fields will - * be filled to ensure backward compatibility. For the others, only - * Instance.logical_interfaces will be filled. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface logical_interfaces = 15; - * @param array<\Google\Cloud\BareMetalSolution\V2\LogicalInterface>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLogicalInterfaces($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\LogicalInterface::class); - $this->logical_interfaces = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance/State.php deleted file mode 100644 index ea236f86c612..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance/State.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.baremetalsolution.v2.Instance.State - */ -class State -{ - /** - * The server is in an unknown state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The server is being provisioned. - * - * Generated from protobuf enum PROVISIONING = 1; - */ - const PROVISIONING = 1; - /** - * The server is running. - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * The server has been deleted. - * - * Generated from protobuf enum DELETED = 3; - */ - const DELETED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PROVISIONING => 'PROVISIONING', - self::RUNNING => 'RUNNING', - self::DELETED => 'DELETED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\Instance_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance_State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance_State.php deleted file mode 100644 index 05727da00631..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Instance_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.ListInstancesRequest - */ -class ListInstancesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListInstancesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Requested page size. Server may return fewer items than requested. - * If unspecified, the server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent value for ListInstancesRequest. Please see - * {@see BareMetalSolutionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListInstancesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListInstancesRequest. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, the server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results from the server. - * @type string $filter - * List filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListInstancesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListInstancesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Requested page size. Server may return fewer items than requested. - * If unspecified, the server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Requested page size. Server may return fewer items than requested. - * If unspecified, the server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListInstancesResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListInstancesResponse.php deleted file mode 100644 index 7bc39330cdee..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListInstancesResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.baremetalsolution.v2.ListInstancesResponse - */ -class ListInstancesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of servers. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Instance instances = 1; - */ - private $instances; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\Instance>|\Google\Protobuf\Internal\RepeatedField $instances - * The list of servers. - * @type string $next_page_token - * A token identifying a page of results from the server. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * The list of servers. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Instance instances = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInstances() - { - return $this->instances; - } - - /** - * The list of servers. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Instance instances = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\Instance>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInstances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Instance::class); - $this->instances = $arr; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsRequest.php deleted file mode 100644 index 46a9980f6ad5..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsRequest.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.baremetalsolution.v2.ListLunsRequest - */ -class ListLunsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListLunsRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. Parent value for ListLunsRequest. Please see - * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListLunsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListLunsRequest. - * @type int $page_size - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results from the server. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Lun::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListLunsRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListLunsRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsResponse.php deleted file mode 100644 index c15be31a1acd..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListLunsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.baremetalsolution.v2.ListLunsResponse - */ -class ListLunsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of luns. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 1; - */ - private $luns; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\Lun>|\Google\Protobuf\Internal\RepeatedField $luns - * The list of luns. - * @type string $next_page_token - * A token identifying a page of results from the server. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Lun::initOnce(); - parent::__construct($data); - } - - /** - * The list of luns. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLuns() - { - return $this->luns; - } - - /** - * The list of luns. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Lun luns = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\Lun>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLuns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Lun::class); - $this->luns = $arr; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageRequest.php deleted file mode 100644 index 6c9b2360d478..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNetworkUsageRequest - */ -class ListNetworkUsageRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value (project and location). - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $location = ''; - - /** - * @param string $location Required. Parent value (project and location). Please see - * {@see BareMetalSolutionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListNetworkUsageRequest - * - * @experimental - */ - public static function build(string $location): self - { - return (new self()) - ->setLocation($location); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $location - * Required. Parent value (project and location). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value (project and location). - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * Required. Parent value (project and location). - * - * Generated from protobuf field string location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageResponse.php deleted file mode 100644 index 322b3281df57..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworkUsageResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNetworkUsageResponse - */ -class ListNetworkUsageResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Networks with IPs. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkUsage networks = 1; - */ - private $networks; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\NetworkUsage>|\Google\Protobuf\Internal\RepeatedField $networks - * Networks with IPs. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Networks with IPs. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkUsage networks = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNetworks() - { - return $this->networks; - } - - /** - * Networks with IPs. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkUsage networks = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\NetworkUsage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNetworks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\NetworkUsage::class); - $this->networks = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksRequest.php deleted file mode 100644 index 83913f7e5766..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksRequest.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNetworksRequest - */ -class ListNetworksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListNetworksRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent value for ListNetworksRequest. Please see - * {@see BareMetalSolutionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListNetworksRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListNetworksRequest. - * @type int $page_size - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results from the server. - * @type string $filter - * List filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListNetworksRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListNetworksRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksResponse.php deleted file mode 100644 index 864d99abb0ef..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNetworksResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNetworksResponse - */ -class ListNetworksResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of networks. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 1; - */ - private $networks; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\Network>|\Google\Protobuf\Internal\RepeatedField $networks - * The list of networks. - * @type string $next_page_token - * A token identifying a page of results from the server. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * The list of networks. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNetworks() - { - return $this->networks; - } - - /** - * The list of networks. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Network networks = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\Network>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNetworks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Network::class); - $this->networks = $arr; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesRequest.php deleted file mode 100644 index cc06bdec66a2..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesRequest.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNfsSharesRequest - */ -class ListNfsSharesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListNfsSharesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent value for ListNfsSharesRequest. Please see - * {@see BareMetalSolutionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListNfsSharesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListNfsSharesRequest. - * @type int $page_size - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results from the server. - * @type string $filter - * List filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListNfsSharesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListNfsSharesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesResponse.php deleted file mode 100644 index 1af3d5e7c36c..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListNfsSharesResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.baremetalsolution.v2.ListNfsSharesResponse - */ -class ListNfsSharesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of NFS shares. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare nfs_shares = 1; - */ - private $nfs_shares; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\NfsShare>|\Google\Protobuf\Internal\RepeatedField $nfs_shares - * The list of NFS shares. - * @type string $next_page_token - * A token identifying a page of results from the server. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * The list of NFS shares. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare nfs_shares = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNfsShares() - { - return $this->nfs_shares; - } - - /** - * The list of NFS shares. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare nfs_shares = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\NfsShare>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNfsShares($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\NfsShare::class); - $this->nfs_shares = $arr; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesRequest.php deleted file mode 100644 index cc4000006dcd..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesRequest.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.baremetalsolution.v2.ListVolumesRequest - */ -class ListVolumesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListVolumesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Parent value for ListVolumesRequest. Please see - * {@see BareMetalSolutionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ListVolumesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListVolumesRequest. - * @type int $page_size - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results from the server. - * @type string $filter - * List filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListVolumesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListVolumesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Requested page size. The server might return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesResponse.php deleted file mode 100644 index c6df4005c656..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ListVolumesResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.baremetalsolution.v2.ListVolumesResponse - */ -class ListVolumesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of storage volumes. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Volume volumes = 1; - */ - private $volumes; - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\Volume>|\Google\Protobuf\Internal\RepeatedField $volumes - * The list of storage volumes. - * @type string $next_page_token - * A token identifying a page of results from the server. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * The list of storage volumes. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Volume volumes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVolumes() - { - return $this->volumes; - } - - /** - * The list of storage volumes. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.Volume volumes = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\Volume>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVolumes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\Volume::class); - $this->volumes = $arr; - - return $this; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results from the server. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface.php deleted file mode 100644 index b813a64ad57a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.baremetalsolution.v2.LogicalInterface - */ -class LogicalInterface extends \Google\Protobuf\Internal\Message -{ - /** - * List of logical network interfaces within a logical interface. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface.LogicalNetworkInterface logical_network_interfaces = 1; - */ - private $logical_network_interfaces; - /** - * Interface name. This is of syntax or and - * forms part of the network template name. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The index of the logical interface mapping to the index of the hardware - * bond or nic on the chosen network template. - * - * Generated from protobuf field int32 interface_index = 3; - */ - protected $interface_index = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BareMetalSolution\V2\LogicalInterface\LogicalNetworkInterface>|\Google\Protobuf\Internal\RepeatedField $logical_network_interfaces - * List of logical network interfaces within a logical interface. - * @type string $name - * Interface name. This is of syntax or and - * forms part of the network template name. - * @type int $interface_index - * The index of the logical interface mapping to the index of the hardware - * bond or nic on the chosen network template. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * List of logical network interfaces within a logical interface. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface.LogicalNetworkInterface logical_network_interfaces = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLogicalNetworkInterfaces() - { - return $this->logical_network_interfaces; - } - - /** - * List of logical network interfaces within a logical interface. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.LogicalInterface.LogicalNetworkInterface logical_network_interfaces = 1; - * @param array<\Google\Cloud\BareMetalSolution\V2\LogicalInterface\LogicalNetworkInterface>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLogicalNetworkInterfaces($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\LogicalInterface\LogicalNetworkInterface::class); - $this->logical_network_interfaces = $arr; - - return $this; - } - - /** - * Interface name. This is of syntax or and - * forms part of the network template name. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Interface name. This is of syntax or and - * forms part of the network template name. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The index of the logical interface mapping to the index of the hardware - * bond or nic on the chosen network template. - * - * Generated from protobuf field int32 interface_index = 3; - * @return int - */ - public function getInterfaceIndex() - { - return $this->interface_index; - } - - /** - * The index of the logical interface mapping to the index of the hardware - * bond or nic on the chosen network template. - * - * Generated from protobuf field int32 interface_index = 3; - * @param int $var - * @return $this - */ - public function setInterfaceIndex($var) - { - GPBUtil::checkInt32($var); - $this->interface_index = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface/LogicalNetworkInterface.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface/LogicalNetworkInterface.php deleted file mode 100644 index f4de9eae30d7..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface/LogicalNetworkInterface.php +++ /dev/null @@ -1,210 +0,0 @@ -google.cloud.baremetalsolution.v2.LogicalInterface.LogicalNetworkInterface - */ -class LogicalNetworkInterface extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the network - * - * Generated from protobuf field string network = 1; - */ - protected $network = ''; - /** - * IP address in the network - * - * Generated from protobuf field string ip_address = 2; - */ - protected $ip_address = ''; - /** - * Whether this interface is the default gateway for the instance. Only - * one interface can be the default gateway for the instance. - * - * Generated from protobuf field bool default_gateway = 3; - */ - protected $default_gateway = false; - /** - * Type of network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type network_type = 4; - */ - protected $network_type = 0; - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 5; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network - * Name of the network - * @type string $ip_address - * IP address in the network - * @type bool $default_gateway - * Whether this interface is the default gateway for the instance. Only - * one interface can be the default gateway for the instance. - * @type int $network_type - * Type of network. - * @type string $id - * An identifier for the `Network`, generated by the backend. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Name of the network - * - * Generated from protobuf field string network = 1; - * @return string - */ - public function getNetwork() - { - return $this->network; - } - - /** - * Name of the network - * - * Generated from protobuf field string network = 1; - * @param string $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkString($var, True); - $this->network = $var; - - return $this; - } - - /** - * IP address in the network - * - * Generated from protobuf field string ip_address = 2; - * @return string - */ - public function getIpAddress() - { - return $this->ip_address; - } - - /** - * IP address in the network - * - * Generated from protobuf field string ip_address = 2; - * @param string $var - * @return $this - */ - public function setIpAddress($var) - { - GPBUtil::checkString($var, True); - $this->ip_address = $var; - - return $this; - } - - /** - * Whether this interface is the default gateway for the instance. Only - * one interface can be the default gateway for the instance. - * - * Generated from protobuf field bool default_gateway = 3; - * @return bool - */ - public function getDefaultGateway() - { - return $this->default_gateway; - } - - /** - * Whether this interface is the default gateway for the instance. Only - * one interface can be the default gateway for the instance. - * - * Generated from protobuf field bool default_gateway = 3; - * @param bool $var - * @return $this - */ - public function setDefaultGateway($var) - { - GPBUtil::checkBool($var); - $this->default_gateway = $var; - - return $this; - } - - /** - * Type of network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type network_type = 4; - * @return int - */ - public function getNetworkType() - { - return $this->network_type; - } - - /** - * Type of network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type network_type = 4; - * @param int $var - * @return $this - */ - public function setNetworkType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Network\Type::class); - $this->network_type = $var; - - return $this; - } - - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 5; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 5; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LogicalNetworkInterface::class, \Google\Cloud\BareMetalSolution\V2\LogicalInterface_LogicalNetworkInterface::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface_LogicalNetworkInterface.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface_LogicalNetworkInterface.php deleted file mode 100644 index dee7d2de3f49..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/LogicalInterface_LogicalNetworkInterface.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.Lun - */ -class Lun extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The name of the LUN. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * An identifier for the LUN, generated by the backend. - * - * Generated from protobuf field string id = 10; - */ - protected $id = ''; - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.State state = 2; - */ - protected $state = 0; - /** - * The size of this LUN, in gigabytes. - * - * Generated from protobuf field int64 size_gb = 3; - */ - protected $size_gb = 0; - /** - * The LUN multiprotocol type ensures the characteristics of the LUN are - * optimized for each operating system. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.MultiprotocolType multiprotocol_type = 4; - */ - protected $multiprotocol_type = 0; - /** - * Display the storage volume for this LUN. - * - * Generated from protobuf field string storage_volume = 5 [(.google.api.resource_reference) = { - */ - protected $storage_volume = ''; - /** - * Display if this LUN can be shared between multiple physical servers. - * - * Generated from protobuf field bool shareable = 6; - */ - protected $shareable = false; - /** - * Display if this LUN is a boot LUN. - * - * Generated from protobuf field bool boot_lun = 7; - */ - protected $boot_lun = false; - /** - * The storage type for this LUN. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.StorageType storage_type = 8; - */ - protected $storage_type = 0; - /** - * The WWID for this LUN. - * - * Generated from protobuf field string wwid = 9; - */ - protected $wwid = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The name of the LUN. - * @type string $id - * An identifier for the LUN, generated by the backend. - * @type int $state - * The state of this storage volume. - * @type int|string $size_gb - * The size of this LUN, in gigabytes. - * @type int $multiprotocol_type - * The LUN multiprotocol type ensures the characteristics of the LUN are - * optimized for each operating system. - * @type string $storage_volume - * Display the storage volume for this LUN. - * @type bool $shareable - * Display if this LUN can be shared between multiple physical servers. - * @type bool $boot_lun - * Display if this LUN is a boot LUN. - * @type int $storage_type - * The storage type for this LUN. - * @type string $wwid - * The WWID for this LUN. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Lun::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The name of the LUN. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The name of the LUN. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * An identifier for the LUN, generated by the backend. - * - * Generated from protobuf field string id = 10; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * An identifier for the LUN, generated by the backend. - * - * Generated from protobuf field string id = 10; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.State state = 2; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.State state = 2; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Lun\State::class); - $this->state = $var; - - return $this; - } - - /** - * The size of this LUN, in gigabytes. - * - * Generated from protobuf field int64 size_gb = 3; - * @return int|string - */ - public function getSizeGb() - { - return $this->size_gb; - } - - /** - * The size of this LUN, in gigabytes. - * - * Generated from protobuf field int64 size_gb = 3; - * @param int|string $var - * @return $this - */ - public function setSizeGb($var) - { - GPBUtil::checkInt64($var); - $this->size_gb = $var; - - return $this; - } - - /** - * The LUN multiprotocol type ensures the characteristics of the LUN are - * optimized for each operating system. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.MultiprotocolType multiprotocol_type = 4; - * @return int - */ - public function getMultiprotocolType() - { - return $this->multiprotocol_type; - } - - /** - * The LUN multiprotocol type ensures the characteristics of the LUN are - * optimized for each operating system. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.MultiprotocolType multiprotocol_type = 4; - * @param int $var - * @return $this - */ - public function setMultiprotocolType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Lun\MultiprotocolType::class); - $this->multiprotocol_type = $var; - - return $this; - } - - /** - * Display the storage volume for this LUN. - * - * Generated from protobuf field string storage_volume = 5 [(.google.api.resource_reference) = { - * @return string - */ - public function getStorageVolume() - { - return $this->storage_volume; - } - - /** - * Display the storage volume for this LUN. - * - * Generated from protobuf field string storage_volume = 5 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setStorageVolume($var) - { - GPBUtil::checkString($var, True); - $this->storage_volume = $var; - - return $this; - } - - /** - * Display if this LUN can be shared between multiple physical servers. - * - * Generated from protobuf field bool shareable = 6; - * @return bool - */ - public function getShareable() - { - return $this->shareable; - } - - /** - * Display if this LUN can be shared between multiple physical servers. - * - * Generated from protobuf field bool shareable = 6; - * @param bool $var - * @return $this - */ - public function setShareable($var) - { - GPBUtil::checkBool($var); - $this->shareable = $var; - - return $this; - } - - /** - * Display if this LUN is a boot LUN. - * - * Generated from protobuf field bool boot_lun = 7; - * @return bool - */ - public function getBootLun() - { - return $this->boot_lun; - } - - /** - * Display if this LUN is a boot LUN. - * - * Generated from protobuf field bool boot_lun = 7; - * @param bool $var - * @return $this - */ - public function setBootLun($var) - { - GPBUtil::checkBool($var); - $this->boot_lun = $var; - - return $this; - } - - /** - * The storage type for this LUN. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.StorageType storage_type = 8; - * @return int - */ - public function getStorageType() - { - return $this->storage_type; - } - - /** - * The storage type for this LUN. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Lun.StorageType storage_type = 8; - * @param int $var - * @return $this - */ - public function setStorageType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Lun\StorageType::class); - $this->storage_type = $var; - - return $this; - } - - /** - * The WWID for this LUN. - * - * Generated from protobuf field string wwid = 9; - * @return string - */ - public function getWwid() - { - return $this->wwid; - } - - /** - * The WWID for this LUN. - * - * Generated from protobuf field string wwid = 9; - * @param string $var - * @return $this - */ - public function setWwid($var) - { - GPBUtil::checkString($var, True); - $this->wwid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/MultiprotocolType.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/MultiprotocolType.php deleted file mode 100644 index c9390ce09906..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/MultiprotocolType.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.baremetalsolution.v2.Lun.MultiprotocolType - */ -class MultiprotocolType -{ - /** - * Server has no OS specified. - * - * Generated from protobuf enum MULTIPROTOCOL_TYPE_UNSPECIFIED = 0; - */ - const MULTIPROTOCOL_TYPE_UNSPECIFIED = 0; - /** - * Server with Linux OS. - * - * Generated from protobuf enum LINUX = 1; - */ - const LINUX = 1; - - private static $valueToName = [ - self::MULTIPROTOCOL_TYPE_UNSPECIFIED => 'MULTIPROTOCOL_TYPE_UNSPECIFIED', - self::LINUX => 'LINUX', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MultiprotocolType::class, \Google\Cloud\BareMetalSolution\V2\Lun_MultiprotocolType::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/State.php deleted file mode 100644 index fc6baf6d1f83..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/State.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.baremetalsolution.v2.Lun.State - */ -class State -{ - /** - * The LUN is in an unknown state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The LUN is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The LUN is being updated. - * - * Generated from protobuf enum UPDATING = 2; - */ - const UPDATING = 2; - /** - * The LUN is ready for use. - * - * Generated from protobuf enum READY = 3; - */ - const READY = 3; - /** - * The LUN has been requested to be deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::READY => 'READY', - self::DELETING => 'DELETING', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\Lun_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/StorageType.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/StorageType.php deleted file mode 100644 index f6896f77e408..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun/StorageType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.Lun.StorageType - */ -class StorageType -{ - /** - * The storage type for this LUN is unknown. - * - * Generated from protobuf enum STORAGE_TYPE_UNSPECIFIED = 0; - */ - const STORAGE_TYPE_UNSPECIFIED = 0; - /** - * This storage type for this LUN is SSD. - * - * Generated from protobuf enum SSD = 1; - */ - const SSD = 1; - /** - * This storage type for this LUN is HDD. - * - * Generated from protobuf enum HDD = 2; - */ - const HDD = 2; - - private static $valueToName = [ - self::STORAGE_TYPE_UNSPECIFIED => 'STORAGE_TYPE_UNSPECIFIED', - self::SSD => 'SSD', - self::HDD => 'HDD', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StorageType::class, \Google\Cloud\BareMetalSolution\V2\Lun_StorageType::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_MultiprotocolType.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_MultiprotocolType.php deleted file mode 100644 index bfa16035ce0a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Lun_MultiprotocolType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.Network - */ -class Network extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this `Network`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/networks/{network}` - * - * Generated from protobuf field string name = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 10; - */ - protected $id = ''; - /** - * The type of this network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type type = 2; - */ - protected $type = 0; - /** - * IP address configured. - * - * Generated from protobuf field string ip_address = 3; - */ - protected $ip_address = ''; - /** - * List of physical interfaces. - * - * Generated from protobuf field repeated string mac_address = 4; - */ - private $mac_address; - /** - * The Network state. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.State state = 6; - */ - protected $state = 0; - /** - * The vlan id of the Network. - * - * Generated from protobuf field string vlan_id = 7; - */ - protected $vlan_id = ''; - /** - * The cidr of the Network. - * - * Generated from protobuf field string cidr = 8; - */ - protected $cidr = ''; - /** - * The vrf for the Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF vrf = 9; - */ - protected $vrf = null; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 11; - */ - private $labels; - /** - * IP range for reserved for services (e.g. NFS). - * - * Generated from protobuf field string services_cidr = 12; - */ - protected $services_cidr = ''; - /** - * List of IP address reservations in this network. - * When updating this field, an error will be generated if a reservation - * conflicts with an IP address already allocated to a physical server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkAddressReservation reservations = 13; - */ - private $reservations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this `Network`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/networks/{network}` - * @type string $id - * An identifier for the `Network`, generated by the backend. - * @type int $type - * The type of this network. - * @type string $ip_address - * IP address configured. - * @type array|\Google\Protobuf\Internal\RepeatedField $mac_address - * List of physical interfaces. - * @type int $state - * The Network state. - * @type string $vlan_id - * The vlan id of the Network. - * @type string $cidr - * The cidr of the Network. - * @type \Google\Cloud\BareMetalSolution\V2\VRF $vrf - * The vrf for the Network. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * @type string $services_cidr - * IP range for reserved for services (e.g. NFS). - * @type array<\Google\Cloud\BareMetalSolution\V2\NetworkAddressReservation>|\Google\Protobuf\Internal\RepeatedField $reservations - * List of IP address reservations in this network. - * When updating this field, an error will be generated if a reservation - * conflicts with an IP address already allocated to a physical server. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this `Network`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/networks/{network}` - * - * Generated from protobuf field string name = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of this `Network`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/networks/{network}` - * - * Generated from protobuf field string name = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 10; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * An identifier for the `Network`, generated by the backend. - * - * Generated from protobuf field string id = 10; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The type of this network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of this network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.Type type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Network\Type::class); - $this->type = $var; - - return $this; - } - - /** - * IP address configured. - * - * Generated from protobuf field string ip_address = 3; - * @return string - */ - public function getIpAddress() - { - return $this->ip_address; - } - - /** - * IP address configured. - * - * Generated from protobuf field string ip_address = 3; - * @param string $var - * @return $this - */ - public function setIpAddress($var) - { - GPBUtil::checkString($var, True); - $this->ip_address = $var; - - return $this; - } - - /** - * List of physical interfaces. - * - * Generated from protobuf field repeated string mac_address = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMacAddress() - { - return $this->mac_address; - } - - /** - * List of physical interfaces. - * - * Generated from protobuf field repeated string mac_address = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMacAddress($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->mac_address = $arr; - - return $this; - } - - /** - * The Network state. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.State state = 6; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The Network state. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network.State state = 6; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Network\State::class); - $this->state = $var; - - return $this; - } - - /** - * The vlan id of the Network. - * - * Generated from protobuf field string vlan_id = 7; - * @return string - */ - public function getVlanId() - { - return $this->vlan_id; - } - - /** - * The vlan id of the Network. - * - * Generated from protobuf field string vlan_id = 7; - * @param string $var - * @return $this - */ - public function setVlanId($var) - { - GPBUtil::checkString($var, True); - $this->vlan_id = $var; - - return $this; - } - - /** - * The cidr of the Network. - * - * Generated from protobuf field string cidr = 8; - * @return string - */ - public function getCidr() - { - return $this->cidr; - } - - /** - * The cidr of the Network. - * - * Generated from protobuf field string cidr = 8; - * @param string $var - * @return $this - */ - public function setCidr($var) - { - GPBUtil::checkString($var, True); - $this->cidr = $var; - - return $this; - } - - /** - * The vrf for the Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF vrf = 9; - * @return \Google\Cloud\BareMetalSolution\V2\VRF|null - */ - public function getVrf() - { - return $this->vrf; - } - - public function hasVrf() - { - return isset($this->vrf); - } - - public function clearVrf() - { - unset($this->vrf); - } - - /** - * The vrf for the Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF vrf = 9; - * @param \Google\Cloud\BareMetalSolution\V2\VRF $var - * @return $this - */ - public function setVrf($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\VRF::class); - $this->vrf = $var; - - return $this; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 11; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 11; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * IP range for reserved for services (e.g. NFS). - * - * Generated from protobuf field string services_cidr = 12; - * @return string - */ - public function getServicesCidr() - { - return $this->services_cidr; - } - - /** - * IP range for reserved for services (e.g. NFS). - * - * Generated from protobuf field string services_cidr = 12; - * @param string $var - * @return $this - */ - public function setServicesCidr($var) - { - GPBUtil::checkString($var, True); - $this->services_cidr = $var; - - return $this; - } - - /** - * List of IP address reservations in this network. - * When updating this field, an error will be generated if a reservation - * conflicts with an IP address already allocated to a physical server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkAddressReservation reservations = 13; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getReservations() - { - return $this->reservations; - } - - /** - * List of IP address reservations in this network. - * When updating this field, an error will be generated if a reservation - * conflicts with an IP address already allocated to a physical server. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NetworkAddressReservation reservations = 13; - * @param array<\Google\Cloud\BareMetalSolution\V2\NetworkAddressReservation>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setReservations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\NetworkAddressReservation::class); - $this->reservations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/State.php deleted file mode 100644 index 1c228e8cb1bb..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/State.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.Network.State - */ -class State -{ - /** - * The Network is in an unknown state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The Network is provisioning. - * - * Generated from protobuf enum PROVISIONING = 1; - */ - const PROVISIONING = 1; - /** - * The Network has been provisioned. - * - * Generated from protobuf enum PROVISIONED = 2; - */ - const PROVISIONED = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PROVISIONING => 'PROVISIONING', - self::PROVISIONED => 'PROVISIONED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\Network_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/Type.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/Type.php deleted file mode 100644 index 5b7a71e8a639..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network/Type.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.baremetalsolution.v2.Network.Type - */ -class Type -{ - /** - * Unspecified value. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Client network, a network peered to a Google Cloud VPC. - * - * Generated from protobuf enum CLIENT = 1; - */ - const CLIENT = 1; - /** - * Private network, a network local to the Bare Metal Solution environment. - * - * Generated from protobuf enum PRIVATE = 2; - */ - const PBPRIVATE = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::CLIENT => 'CLIENT', - self::PBPRIVATE => 'PRIVATE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\BareMetalSolution\V2\Network_Type::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkAddressReservation.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkAddressReservation.php deleted file mode 100644 index e9164232774a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkAddressReservation.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.baremetalsolution.v2.NetworkAddressReservation - */ -class NetworkAddressReservation extends \Google\Protobuf\Internal\Message -{ - /** - * The first address of this reservation block. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string start_address = 1; - */ - protected $start_address = ''; - /** - * The last address of this reservation block, inclusive. I.e., for cases when - * reservations are only single addresses, end_address and start_address will - * be the same. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string end_address = 2; - */ - protected $end_address = ''; - /** - * A note about this reservation, intended for human consumption. - * - * Generated from protobuf field string note = 3; - */ - protected $note = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $start_address - * The first address of this reservation block. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * @type string $end_address - * The last address of this reservation block, inclusive. I.e., for cases when - * reservations are only single addresses, end_address and start_address will - * be the same. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * @type string $note - * A note about this reservation, intended for human consumption. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * The first address of this reservation block. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string start_address = 1; - * @return string - */ - public function getStartAddress() - { - return $this->start_address; - } - - /** - * The first address of this reservation block. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string start_address = 1; - * @param string $var - * @return $this - */ - public function setStartAddress($var) - { - GPBUtil::checkString($var, True); - $this->start_address = $var; - - return $this; - } - - /** - * The last address of this reservation block, inclusive. I.e., for cases when - * reservations are only single addresses, end_address and start_address will - * be the same. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string end_address = 2; - * @return string - */ - public function getEndAddress() - { - return $this->end_address; - } - - /** - * The last address of this reservation block, inclusive. I.e., for cases when - * reservations are only single addresses, end_address and start_address will - * be the same. - * Must be specified as a single IPv4 address, e.g. 10.1.2.2. - * - * Generated from protobuf field string end_address = 2; - * @param string $var - * @return $this - */ - public function setEndAddress($var) - { - GPBUtil::checkString($var, True); - $this->end_address = $var; - - return $this; - } - - /** - * A note about this reservation, intended for human consumption. - * - * Generated from protobuf field string note = 3; - * @return string - */ - public function getNote() - { - return $this->note; - } - - /** - * A note about this reservation, intended for human consumption. - * - * Generated from protobuf field string note = 3; - * @param string $var - * @return $this - */ - public function setNote($var) - { - GPBUtil::checkString($var, True); - $this->note = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkUsage.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkUsage.php deleted file mode 100644 index 789ec3aa94c0..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NetworkUsage.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.baremetalsolution.v2.NetworkUsage - */ -class NetworkUsage extends \Google\Protobuf\Internal\Message -{ - /** - * Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1; - */ - protected $network = null; - /** - * All used IP addresses in this network. - * - * Generated from protobuf field repeated string used_ips = 2; - */ - private $used_ips; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BareMetalSolution\V2\Network $network - * Network. - * @type array|\Google\Protobuf\Internal\RepeatedField $used_ips - * All used IP addresses in this network. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1; - * @return \Google\Cloud\BareMetalSolution\V2\Network|null - */ - public function getNetwork() - { - return $this->network; - } - - public function hasNetwork() - { - return isset($this->network); - } - - public function clearNetwork() - { - unset($this->network); - } - - /** - * Network. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1; - * @param \Google\Cloud\BareMetalSolution\V2\Network $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\Network::class); - $this->network = $var; - - return $this; - } - - /** - * All used IP addresses in this network. - * - * Generated from protobuf field repeated string used_ips = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUsedIps() - { - return $this->used_ips; - } - - /** - * All used IP addresses in this network. - * - * Generated from protobuf field repeated string used_ips = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUsedIps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->used_ips = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network_State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network_State.php deleted file mode 100644 index df0a268d9c5f..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Network_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.NfsShare - */ -class NfsShare extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The name of the NFS share. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. An identifier for the NFS share, generated by the backend. - * - * Generated from protobuf field string nfs_share_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $nfs_share_id = ''; - /** - * The state of the NFS share. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.State state = 3; - */ - protected $state = 0; - /** - * The volume containing the share. - * - * Generated from protobuf field string volume = 4 [(.google.api.resource_reference) = { - */ - protected $volume = ''; - /** - * List of allowed access points. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare.AllowedClient allowed_clients = 5; - */ - private $allowed_clients; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 6; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The name of the NFS share. - * @type string $nfs_share_id - * Output only. An identifier for the NFS share, generated by the backend. - * @type int $state - * The state of the NFS share. - * @type string $volume - * The volume containing the share. - * @type array<\Google\Cloud\BareMetalSolution\V2\NfsShare\AllowedClient>|\Google\Protobuf\Internal\RepeatedField $allowed_clients - * List of allowed access points. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The name of the NFS share. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The name of the NFS share. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. An identifier for the NFS share, generated by the backend. - * - * Generated from protobuf field string nfs_share_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNfsShareId() - { - return $this->nfs_share_id; - } - - /** - * Output only. An identifier for the NFS share, generated by the backend. - * - * Generated from protobuf field string nfs_share_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setNfsShareId($var) - { - GPBUtil::checkString($var, True); - $this->nfs_share_id = $var; - - return $this; - } - - /** - * The state of the NFS share. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.State state = 3; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of the NFS share. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.State state = 3; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\NfsShare\State::class); - $this->state = $var; - - return $this; - } - - /** - * The volume containing the share. - * - * Generated from protobuf field string volume = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getVolume() - { - return $this->volume; - } - - /** - * The volume containing the share. - * - * Generated from protobuf field string volume = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVolume($var) - { - GPBUtil::checkString($var, True); - $this->volume = $var; - - return $this; - } - - /** - * List of allowed access points. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare.AllowedClient allowed_clients = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedClients() - { - return $this->allowed_clients; - } - - /** - * List of allowed access points. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.NfsShare.AllowedClient allowed_clients = 5; - * @param array<\Google\Cloud\BareMetalSolution\V2\NfsShare\AllowedClient>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedClients($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\NfsShare\AllowedClient::class); - $this->allowed_clients = $arr; - - return $this; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 6; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 6; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/AllowedClient.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/AllowedClient.php deleted file mode 100644 index 0bf81d2d467a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/AllowedClient.php +++ /dev/null @@ -1,282 +0,0 @@ -google.cloud.baremetalsolution.v2.NfsShare.AllowedClient - */ -class AllowedClient extends \Google\Protobuf\Internal\Message -{ - /** - * The network the access point sits on. - * - * Generated from protobuf field string network = 1 [(.google.api.resource_reference) = { - */ - protected $network = ''; - /** - * The IP address of the share on this network. - * - * Generated from protobuf field string share_ip = 2; - */ - protected $share_ip = ''; - /** - * The subnet of IP addresses permitted to access the share. - * - * Generated from protobuf field string allowed_clients_cidr = 3; - */ - protected $allowed_clients_cidr = ''; - /** - * Mount permissions. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.MountPermissions mount_permissions = 4; - */ - protected $mount_permissions = 0; - /** - * Allow dev flag. Which controls whether to allow creation of devices. - * - * Generated from protobuf field bool allow_dev = 5; - */ - protected $allow_dev = false; - /** - * Allow the setuid flag. - * - * Generated from protobuf field bool allow_suid = 6; - */ - protected $allow_suid = false; - /** - * Disable root squashing, which is a feature of NFS. - * Root squash is a special mapping of the remote superuser (root) identity - * when using identity authentication. - * - * Generated from protobuf field bool no_root_squash = 7; - */ - protected $no_root_squash = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network - * The network the access point sits on. - * @type string $share_ip - * The IP address of the share on this network. - * @type string $allowed_clients_cidr - * The subnet of IP addresses permitted to access the share. - * @type int $mount_permissions - * Mount permissions. - * @type bool $allow_dev - * Allow dev flag. Which controls whether to allow creation of devices. - * @type bool $allow_suid - * Allow the setuid flag. - * @type bool $no_root_squash - * Disable root squashing, which is a feature of NFS. - * Root squash is a special mapping of the remote superuser (root) identity - * when using identity authentication. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * The network the access point sits on. - * - * Generated from protobuf field string network = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getNetwork() - { - return $this->network; - } - - /** - * The network the access point sits on. - * - * Generated from protobuf field string network = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkString($var, True); - $this->network = $var; - - return $this; - } - - /** - * The IP address of the share on this network. - * - * Generated from protobuf field string share_ip = 2; - * @return string - */ - public function getShareIp() - { - return $this->share_ip; - } - - /** - * The IP address of the share on this network. - * - * Generated from protobuf field string share_ip = 2; - * @param string $var - * @return $this - */ - public function setShareIp($var) - { - GPBUtil::checkString($var, True); - $this->share_ip = $var; - - return $this; - } - - /** - * The subnet of IP addresses permitted to access the share. - * - * Generated from protobuf field string allowed_clients_cidr = 3; - * @return string - */ - public function getAllowedClientsCidr() - { - return $this->allowed_clients_cidr; - } - - /** - * The subnet of IP addresses permitted to access the share. - * - * Generated from protobuf field string allowed_clients_cidr = 3; - * @param string $var - * @return $this - */ - public function setAllowedClientsCidr($var) - { - GPBUtil::checkString($var, True); - $this->allowed_clients_cidr = $var; - - return $this; - } - - /** - * Mount permissions. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.MountPermissions mount_permissions = 4; - * @return int - */ - public function getMountPermissions() - { - return $this->mount_permissions; - } - - /** - * Mount permissions. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare.MountPermissions mount_permissions = 4; - * @param int $var - * @return $this - */ - public function setMountPermissions($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\NfsShare\MountPermissions::class); - $this->mount_permissions = $var; - - return $this; - } - - /** - * Allow dev flag. Which controls whether to allow creation of devices. - * - * Generated from protobuf field bool allow_dev = 5; - * @return bool - */ - public function getAllowDev() - { - return $this->allow_dev; - } - - /** - * Allow dev flag. Which controls whether to allow creation of devices. - * - * Generated from protobuf field bool allow_dev = 5; - * @param bool $var - * @return $this - */ - public function setAllowDev($var) - { - GPBUtil::checkBool($var); - $this->allow_dev = $var; - - return $this; - } - - /** - * Allow the setuid flag. - * - * Generated from protobuf field bool allow_suid = 6; - * @return bool - */ - public function getAllowSuid() - { - return $this->allow_suid; - } - - /** - * Allow the setuid flag. - * - * Generated from protobuf field bool allow_suid = 6; - * @param bool $var - * @return $this - */ - public function setAllowSuid($var) - { - GPBUtil::checkBool($var); - $this->allow_suid = $var; - - return $this; - } - - /** - * Disable root squashing, which is a feature of NFS. - * Root squash is a special mapping of the remote superuser (root) identity - * when using identity authentication. - * - * Generated from protobuf field bool no_root_squash = 7; - * @return bool - */ - public function getNoRootSquash() - { - return $this->no_root_squash; - } - - /** - * Disable root squashing, which is a feature of NFS. - * Root squash is a special mapping of the remote superuser (root) identity - * when using identity authentication. - * - * Generated from protobuf field bool no_root_squash = 7; - * @param bool $var - * @return $this - */ - public function setNoRootSquash($var) - { - GPBUtil::checkBool($var); - $this->no_root_squash = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AllowedClient::class, \Google\Cloud\BareMetalSolution\V2\NfsShare_AllowedClient::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/MountPermissions.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/MountPermissions.php deleted file mode 100644 index dadf339aea7f..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/MountPermissions.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.NfsShare.MountPermissions - */ -class MountPermissions -{ - /** - * Permissions were not specified. - * - * Generated from protobuf enum MOUNT_PERMISSIONS_UNSPECIFIED = 0; - */ - const MOUNT_PERMISSIONS_UNSPECIFIED = 0; - /** - * NFS share can be mount with read-only permissions. - * - * Generated from protobuf enum READ = 1; - */ - const READ = 1; - /** - * NFS share can be mount with read-write permissions. - * - * Generated from protobuf enum READ_WRITE = 2; - */ - const READ_WRITE = 2; - - private static $valueToName = [ - self::MOUNT_PERMISSIONS_UNSPECIFIED => 'MOUNT_PERMISSIONS_UNSPECIFIED', - self::READ => 'READ', - self::READ_WRITE => 'READ_WRITE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MountPermissions::class, \Google\Cloud\BareMetalSolution\V2\NfsShare_MountPermissions::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/State.php deleted file mode 100644 index b2088a2aa357..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare/State.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.baremetalsolution.v2.NfsShare.State - */ -class State -{ - /** - * The share is in an unknown state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The share has been provisioned. - * - * Generated from protobuf enum PROVISIONED = 1; - */ - const PROVISIONED = 1; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PROVISIONED => 'PROVISIONED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\NfsShare_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_AllowedClient.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_AllowedClient.php deleted file mode 100644 index 9f5878ba7c47..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/NfsShare_AllowedClient.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Name of the action executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Identifies whether the user requested the cancellation - * of the operation. Operations that have been successfully cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * API version used with the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * The time the operation finished running. - * @type string $target - * Server-defined resource path for the target of the operation. - * @type string $verb - * Name of the action executed by the operation. - * @type string $status_message - * Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Identifies whether the user requested the cancellation - * of the operation. Operations that have been successfully cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][] of 1, - * corresponding to `Code.CANCELLED`. - * @type string $api_version - * API version used with the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Baremetalsolution::initOnce(); - parent::__construct($data); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Name of the action executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Name of the action executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Identifies whether the user requested the cancellation - * of the operation. Operations that have been successfully cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Identifies whether the user requested the cancellation - * of the operation. Operations that have been successfully cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * API version used with the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * API version used with the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceRequest.php deleted file mode 100644 index fad5d2770386..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.ResetInstanceRequest - */ -class ResetInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\ResetInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceResponse.php deleted file mode 100644 index 013bd1cf5868..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResetInstanceResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.baremetalsolution.v2.ResetInstanceResponse - */ -class ResetInstanceResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Baremetalsolution::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResizeVolumeRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResizeVolumeRequest.php deleted file mode 100644 index 7cb2d386c502..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ResizeVolumeRequest.php +++ /dev/null @@ -1,117 +0,0 @@ -google.cloud.baremetalsolution.v2.ResizeVolumeRequest - */ -class ResizeVolumeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Volume to resize. - * - * Generated from protobuf field string volume = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $volume = ''; - /** - * New Volume size, in GiB. - * - * Generated from protobuf field int64 size_gib = 2; - */ - protected $size_gib = 0; - - /** - * @param string $volume Required. Volume to resize. Please see - * {@see BareMetalSolutionClient::volumeName()} for help formatting this field. - * @param int $sizeGib New Volume size, in GiB. - * - * @return \Google\Cloud\BareMetalSolution\V2\ResizeVolumeRequest - * - * @experimental - */ - public static function build(string $volume, int $sizeGib): self - { - return (new self()) - ->setVolume($volume) - ->setSizeGib($sizeGib); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $volume - * Required. Volume to resize. - * @type int|string $size_gib - * New Volume size, in GiB. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Required. Volume to resize. - * - * Generated from protobuf field string volume = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getVolume() - { - return $this->volume; - } - - /** - * Required. Volume to resize. - * - * Generated from protobuf field string volume = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVolume($var) - { - GPBUtil::checkString($var, True); - $this->volume = $var; - - return $this; - } - - /** - * New Volume size, in GiB. - * - * Generated from protobuf field int64 size_gib = 2; - * @return int|string - */ - public function getSizeGib() - { - return $this->size_gib; - } - - /** - * New Volume size, in GiB. - * - * Generated from protobuf field int64 size_gib = 2; - * @param int|string $var - * @return $this - */ - public function setSizeGib($var) - { - GPBUtil::checkInt64($var); - $this->size_gib = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate.php deleted file mode 100644 index 3e5caba5f180..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.baremetalsolution.v2.ServerNetworkTemplate - */ -class ServerNetworkTemplate extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Template's unique name. The full resource name follows the pattern: - * `projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}` - * Generally, the {server_network_template} follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Instance types this template is applicable to. - * - * Generated from protobuf field repeated string applicable_instance_types = 2; - */ - private $applicable_instance_types; - /** - * Logical interfaces. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface logical_interfaces = 3; - */ - private $logical_interfaces; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Template's unique name. The full resource name follows the pattern: - * `projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}` - * Generally, the {server_network_template} follows the syntax of - * "bond" or "nic". - * @type array|\Google\Protobuf\Internal\RepeatedField $applicable_instance_types - * Instance types this template is applicable to. - * @type array<\Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate\LogicalInterface>|\Google\Protobuf\Internal\RepeatedField $logical_interfaces - * Logical interfaces. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Template's unique name. The full resource name follows the pattern: - * `projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}` - * Generally, the {server_network_template} follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Template's unique name. The full resource name follows the pattern: - * `projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}` - * Generally, the {server_network_template} follows the syntax of - * "bond" or "nic". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Instance types this template is applicable to. - * - * Generated from protobuf field repeated string applicable_instance_types = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApplicableInstanceTypes() - { - return $this->applicable_instance_types; - } - - /** - * Instance types this template is applicable to. - * - * Generated from protobuf field repeated string applicable_instance_types = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApplicableInstanceTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->applicable_instance_types = $arr; - - return $this; - } - - /** - * Logical interfaces. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface logical_interfaces = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLogicalInterfaces() - { - return $this->logical_interfaces; - } - - /** - * Logical interfaces. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface logical_interfaces = 3; - * @param array<\Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate\LogicalInterface>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLogicalInterfaces($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate\LogicalInterface::class); - $this->logical_interfaces = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface.php deleted file mode 100644 index 96085db3f668..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface.php +++ /dev/null @@ -1,154 +0,0 @@ -google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface - */ -class LogicalInterface extends \Google\Protobuf\Internal\Message -{ - /** - * Interface name. - * This is not a globally unique identifier. - * Name is unique only inside the ServerNetworkTemplate. This is of syntax - * or - * and forms part of the network template name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Interface type. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface.InterfaceType type = 2; - */ - protected $type = 0; - /** - * If true, interface must have network connected. - * - * Generated from protobuf field bool required = 3; - */ - protected $required = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Interface name. - * This is not a globally unique identifier. - * Name is unique only inside the ServerNetworkTemplate. This is of syntax - * or - * and forms part of the network template name. - * @type int $type - * Interface type. - * @type bool $required - * If true, interface must have network connected. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Interface name. - * This is not a globally unique identifier. - * Name is unique only inside the ServerNetworkTemplate. This is of syntax - * or - * and forms part of the network template name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Interface name. - * This is not a globally unique identifier. - * Name is unique only inside the ServerNetworkTemplate. This is of syntax - * or - * and forms part of the network template name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Interface type. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface.InterfaceType type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Interface type. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface.InterfaceType type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate\LogicalInterface\InterfaceType::class); - $this->type = $var; - - return $this; - } - - /** - * If true, interface must have network connected. - * - * Generated from protobuf field bool required = 3; - * @return bool - */ - public function getRequired() - { - return $this->required; - } - - /** - * If true, interface must have network connected. - * - * Generated from protobuf field bool required = 3; - * @param bool $var - * @return $this - */ - public function setRequired($var) - { - GPBUtil::checkBool($var); - $this->required = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LogicalInterface::class, \Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate_LogicalInterface::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface/InterfaceType.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface/InterfaceType.php deleted file mode 100644 index 45e03a1e7723..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate/LogicalInterface/InterfaceType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.ServerNetworkTemplate.LogicalInterface.InterfaceType - */ -class InterfaceType -{ - /** - * Unspecified value. - * - * Generated from protobuf enum INTERFACE_TYPE_UNSPECIFIED = 0; - */ - const INTERFACE_TYPE_UNSPECIFIED = 0; - /** - * Bond interface type. - * - * Generated from protobuf enum BOND = 1; - */ - const BOND = 1; - /** - * NIC interface type. - * - * Generated from protobuf enum NIC = 2; - */ - const NIC = 2; - - private static $valueToName = [ - self::INTERFACE_TYPE_UNSPECIFIED => 'INTERFACE_TYPE_UNSPECIFIED', - self::BOND => 'BOND', - self::NIC => 'NIC', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InterfaceType::class, \Google\Cloud\BareMetalSolution\V2\ServerNetworkTemplate_LogicalInterface_InterfaceType::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate_LogicalInterface.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate_LogicalInterface.php deleted file mode 100644 index 3f7f085734e0..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/ServerNetworkTemplate_LogicalInterface.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.StartInstanceRequest - */ -class StartInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\StartInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StartInstanceResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StartInstanceResponse.php deleted file mode 100644 index 078df2aa2efa..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StartInstanceResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.baremetalsolution.v2.StartInstanceResponse - */ -class StartInstanceResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceRequest.php deleted file mode 100644 index c838273d1284..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.baremetalsolution.v2.StopInstanceRequest - */ -class StopInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see BareMetalSolutionClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\BareMetalSolution\V2\StopInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceResponse.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceResponse.php deleted file mode 100644 index f481f45b43fe..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/StopInstanceResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.baremetalsolution.v2.StopInstanceResponse - */ -class StopInstanceResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateInstanceRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateInstanceRequest.php deleted file mode 100644 index 60546eef353a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateInstanceRequest.php +++ /dev/null @@ -1,167 +0,0 @@ -google.cloud.baremetalsolution.v2.UpdateInstanceRequest - */ -class UpdateInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The server to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance = null; - /** - * The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\BareMetalSolution\V2\Instance $instance Required. The server to update. - * - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * - * @return \Google\Cloud\BareMetalSolution\V2\UpdateInstanceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BareMetalSolution\V2\Instance $instance, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setInstance($instance) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BareMetalSolution\V2\Instance $instance - * Required. The server to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Instance::initOnce(); - parent::__construct($data); - } - - /** - * Required. The server to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BareMetalSolution\V2\Instance|null - */ - public function getInstance() - { - return $this->instance; - } - - public function hasInstance() - { - return isset($this->instance); - } - - public function clearInstance() - { - unset($this->instance); - } - - /** - * Required. The server to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BareMetalSolution\V2\Instance $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\Instance::class); - $this->instance = $var; - - return $this; - } - - /** - * The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNetworkRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNetworkRequest.php deleted file mode 100644 index b37c8da91340..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNetworkRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.baremetalsolution.v2.UpdateNetworkRequest - */ -class UpdateNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The network to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network = null; - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\BareMetalSolution\V2\Network $network Required. The network to update. - * - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * - * @return \Google\Cloud\BareMetalSolution\V2\UpdateNetworkRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BareMetalSolution\V2\Network $network, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNetwork($network) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BareMetalSolution\V2\Network $network - * Required. The network to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * Required. The network to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BareMetalSolution\V2\Network|null - */ - public function getNetwork() - { - return $this->network; - } - - public function hasNetwork() - { - return isset($this->network); - } - - public function clearNetwork() - { - unset($this->network); - } - - /** - * Required. The network to update. - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Network network = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BareMetalSolution\V2\Network $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\Network::class); - $this->network = $var; - - return $this; - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNfsShareRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNfsShareRequest.php deleted file mode 100644 index de590206ada5..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateNfsShareRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.baremetalsolution.v2.UpdateNfsShareRequest - */ -class UpdateNfsShareRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The NFS share to update. - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $nfs_share = null; - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\BareMetalSolution\V2\NfsShare $nfsShare Required. The NFS share to update. - * - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. - * The only currently supported fields are: - * `labels` - * - * @return \Google\Cloud\BareMetalSolution\V2\UpdateNfsShareRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BareMetalSolution\V2\NfsShare $nfsShare, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNfsShare($nfsShare) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BareMetalSolution\V2\NfsShare $nfs_share - * Required. The NFS share to update. - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. - * The only currently supported fields are: - * `labels` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce(); - parent::__construct($data); - } - - /** - * Required. The NFS share to update. - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BareMetalSolution\V2\NfsShare|null - */ - public function getNfsShare() - { - return $this->nfs_share; - } - - public function hasNfsShare() - { - return isset($this->nfs_share); - } - - public function clearNfsShare() - { - unset($this->nfs_share); - } - - /** - * Required. The NFS share to update. - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BareMetalSolution\V2\NfsShare $var - * @return $this - */ - public function setNfsShare($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\NfsShare::class); - $this->nfs_share = $var; - - return $this; - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `labels` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateVolumeRequest.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateVolumeRequest.php deleted file mode 100644 index 7ec9bcd90128..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/UpdateVolumeRequest.php +++ /dev/null @@ -1,177 +0,0 @@ -google.cloud.baremetalsolution.v2.UpdateVolumeRequest - */ -class UpdateVolumeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The volume to update. - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume volume = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $volume = null; - /** - * The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\BareMetalSolution\V2\Volume $volume Required. The volume to update. - * - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * - * @return \Google\Cloud\BareMetalSolution\V2\UpdateVolumeRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BareMetalSolution\V2\Volume $volume, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setVolume($volume) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BareMetalSolution\V2\Volume $volume - * Required. The volume to update. - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Required. The volume to update. - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume volume = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BareMetalSolution\V2\Volume|null - */ - public function getVolume() - { - return $this->volume; - } - - public function hasVolume() - { - return isset($this->volume); - } - - public function clearVolume() - { - unset($this->volume); - } - - /** - * Required. The volume to update. - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume volume = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BareMetalSolution\V2\Volume $var - * @return $this - */ - public function setVolume($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\Volume::class); - $this->volume = $var; - - return $this; - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF.php deleted file mode 100644 index 03ed7096947b..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF.php +++ /dev/null @@ -1,179 +0,0 @@ -google.cloud.baremetalsolution.v2.VRF - */ -class VRF extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the VRF. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The possible state of VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.State state = 5; - */ - protected $state = 0; - /** - * The QOS policy applied to this VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; - */ - protected $qos_policy = null; - /** - * The list of VLAN attachments for the VRF. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; - */ - private $vlan_attachments; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the VRF. - * @type int $state - * The possible state of VRF. - * @type \Google\Cloud\BareMetalSolution\V2\VRF\QosPolicy $qos_policy - * The QOS policy applied to this VRF. - * @type array<\Google\Cloud\BareMetalSolution\V2\VRF\VlanAttachment>|\Google\Protobuf\Internal\RepeatedField $vlan_attachments - * The list of VLAN attachments for the VRF. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * The name of the VRF. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the VRF. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The possible state of VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.State state = 5; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The possible state of VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.State state = 5; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\VRF\State::class); - $this->state = $var; - - return $this; - } - - /** - * The QOS policy applied to this VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; - * @return \Google\Cloud\BareMetalSolution\V2\VRF\QosPolicy|null - */ - public function getQosPolicy() - { - return $this->qos_policy; - } - - public function hasQosPolicy() - { - return isset($this->qos_policy); - } - - public function clearQosPolicy() - { - unset($this->qos_policy); - } - - /** - * The QOS policy applied to this VRF. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; - * @param \Google\Cloud\BareMetalSolution\V2\VRF\QosPolicy $var - * @return $this - */ - public function setQosPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\VRF\QosPolicy::class); - $this->qos_policy = $var; - - return $this; - } - - /** - * The list of VLAN attachments for the VRF. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVlanAttachments() - { - return $this->vlan_attachments; - } - - /** - * The list of VLAN attachments for the VRF. - * - * Generated from protobuf field repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; - * @param array<\Google\Cloud\BareMetalSolution\V2\VRF\VlanAttachment>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVlanAttachments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BareMetalSolution\V2\VRF\VlanAttachment::class); - $this->vlan_attachments = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/QosPolicy.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/QosPolicy.php deleted file mode 100644 index 155de6cc6ac3..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/QosPolicy.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.baremetalsolution.v2.VRF.QosPolicy - */ -class QosPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The bandwidth permitted by the QOS policy, in gbps. - * - * Generated from protobuf field double bandwidth_gbps = 1; - */ - protected $bandwidth_gbps = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $bandwidth_gbps - * The bandwidth permitted by the QOS policy, in gbps. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * The bandwidth permitted by the QOS policy, in gbps. - * - * Generated from protobuf field double bandwidth_gbps = 1; - * @return float - */ - public function getBandwidthGbps() - { - return $this->bandwidth_gbps; - } - - /** - * The bandwidth permitted by the QOS policy, in gbps. - * - * Generated from protobuf field double bandwidth_gbps = 1; - * @param float $var - * @return $this - */ - public function setBandwidthGbps($var) - { - GPBUtil::checkDouble($var); - $this->bandwidth_gbps = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(QosPolicy::class, \Google\Cloud\BareMetalSolution\V2\VRF_QosPolicy::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/State.php deleted file mode 100644 index 77a76204cece..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/State.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.VRF.State - */ -class State -{ - /** - * The unspecified state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The vrf is provisioning. - * - * Generated from protobuf enum PROVISIONING = 1; - */ - const PROVISIONING = 1; - /** - * The vrf is provisioned. - * - * Generated from protobuf enum PROVISIONED = 2; - */ - const PROVISIONED = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PROVISIONING => 'PROVISIONING', - self::PROVISIONED => 'PROVISIONED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\VRF_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/VlanAttachment.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/VlanAttachment.php deleted file mode 100644 index 9923f8d4ae9a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF/VlanAttachment.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.baremetalsolution.v2.VRF.VlanAttachment - */ -class VlanAttachment extends \Google\Protobuf\Internal\Message -{ - /** - * The peer vlan ID of the attachment. - * - * Generated from protobuf field int64 peer_vlan_id = 1; - */ - protected $peer_vlan_id = 0; - /** - * The peer IP of the attachment. - * - * Generated from protobuf field string peer_ip = 2; - */ - protected $peer_ip = ''; - /** - * The router IP of the attachment. - * - * Generated from protobuf field string router_ip = 3; - */ - protected $router_ip = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $peer_vlan_id - * The peer vlan ID of the attachment. - * @type string $peer_ip - * The peer IP of the attachment. - * @type string $router_ip - * The router IP of the attachment. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Network::initOnce(); - parent::__construct($data); - } - - /** - * The peer vlan ID of the attachment. - * - * Generated from protobuf field int64 peer_vlan_id = 1; - * @return int|string - */ - public function getPeerVlanId() - { - return $this->peer_vlan_id; - } - - /** - * The peer vlan ID of the attachment. - * - * Generated from protobuf field int64 peer_vlan_id = 1; - * @param int|string $var - * @return $this - */ - public function setPeerVlanId($var) - { - GPBUtil::checkInt64($var); - $this->peer_vlan_id = $var; - - return $this; - } - - /** - * The peer IP of the attachment. - * - * Generated from protobuf field string peer_ip = 2; - * @return string - */ - public function getPeerIp() - { - return $this->peer_ip; - } - - /** - * The peer IP of the attachment. - * - * Generated from protobuf field string peer_ip = 2; - * @param string $var - * @return $this - */ - public function setPeerIp($var) - { - GPBUtil::checkString($var, True); - $this->peer_ip = $var; - - return $this; - } - - /** - * The router IP of the attachment. - * - * Generated from protobuf field string router_ip = 3; - * @return string - */ - public function getRouterIp() - { - return $this->router_ip; - } - - /** - * The router IP of the attachment. - * - * Generated from protobuf field string router_ip = 3; - * @param string $var - * @return $this - */ - public function setRouterIp($var) - { - GPBUtil::checkString($var, True); - $this->router_ip = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(VlanAttachment::class, \Google\Cloud\BareMetalSolution\V2\VRF_VlanAttachment::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_QosPolicy.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_QosPolicy.php deleted file mode 100644 index 8bcd2d4b87f1..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/VRF_QosPolicy.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.baremetalsolution.v2.Volume - */ -class Volume extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this `Volume`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/volumes/{volume}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * An identifier for the `Volume`, generated by the backend. - * - * Generated from protobuf field string id = 11; - */ - protected $id = ''; - /** - * The storage type for this volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.StorageType storage_type = 2; - */ - protected $storage_type = 0; - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.State state = 3; - */ - protected $state = 0; - /** - * The requested size of this storage volume, in GiB. - * - * Generated from protobuf field int64 requested_size_gib = 4; - */ - protected $requested_size_gib = 0; - /** - * The current size of this storage volume, in GiB, including space reserved - * for snapshots. This size might be different than the requested size if the - * storage volume has been configured with auto grow or auto shrink. - * - * Generated from protobuf field int64 current_size_gib = 5; - */ - protected $current_size_gib = 0; - /** - * Additional emergency size that was requested for this Volume, in GiB. - * current_size_gib includes this value. - * - * Generated from protobuf field int64 emergency_size_gib = 14; - */ - protected $emergency_size_gib = 0; - /** - * The size, in GiB, that this storage volume has expanded as a result of an - * auto grow policy. In the absence of auto-grow, the value is 0. - * - * Generated from protobuf field int64 auto_grown_size_gib = 6; - */ - protected $auto_grown_size_gib = 0; - /** - * The space remaining in the storage volume for new LUNs, in GiB, excluding - * space reserved for snapshots. - * - * Generated from protobuf field int64 remaining_space_gib = 7; - */ - protected $remaining_space_gib = 0; - /** - * Details about snapshot space reservation and usage on the storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotReservationDetail snapshot_reservation_detail = 8; - */ - protected $snapshot_reservation_detail = null; - /** - * The behavior to use when snapshot reserved space is full. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotAutoDeleteBehavior snapshot_auto_delete_behavior = 9; - */ - protected $snapshot_auto_delete_behavior = 0; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 12; - */ - private $labels; - /** - * Whether snapshots are enabled. - * - * Generated from protobuf field bool snapshot_enabled = 13; - */ - protected $snapshot_enabled = false; - /** - * Immutable. Pod name. - * - * Generated from protobuf field string pod = 15 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $pod = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this `Volume`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/volumes/{volume}` - * @type string $id - * An identifier for the `Volume`, generated by the backend. - * @type int $storage_type - * The storage type for this volume. - * @type int $state - * The state of this storage volume. - * @type int|string $requested_size_gib - * The requested size of this storage volume, in GiB. - * @type int|string $current_size_gib - * The current size of this storage volume, in GiB, including space reserved - * for snapshots. This size might be different than the requested size if the - * storage volume has been configured with auto grow or auto shrink. - * @type int|string $emergency_size_gib - * Additional emergency size that was requested for this Volume, in GiB. - * current_size_gib includes this value. - * @type int|string $auto_grown_size_gib - * The size, in GiB, that this storage volume has expanded as a result of an - * auto grow policy. In the absence of auto-grow, the value is 0. - * @type int|string $remaining_space_gib - * The space remaining in the storage volume for new LUNs, in GiB, excluding - * space reserved for snapshots. - * @type \Google\Cloud\BareMetalSolution\V2\Volume\SnapshotReservationDetail $snapshot_reservation_detail - * Details about snapshot space reservation and usage on the storage volume. - * @type int $snapshot_auto_delete_behavior - * The behavior to use when snapshot reserved space is full. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * @type bool $snapshot_enabled - * Whether snapshots are enabled. - * @type string $pod - * Immutable. Pod name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this `Volume`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/volumes/{volume}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of this `Volume`. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * Format: - * `projects/{project}/locations/{location}/volumes/{volume}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * An identifier for the `Volume`, generated by the backend. - * - * Generated from protobuf field string id = 11; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * An identifier for the `Volume`, generated by the backend. - * - * Generated from protobuf field string id = 11; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The storage type for this volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.StorageType storage_type = 2; - * @return int - */ - public function getStorageType() - { - return $this->storage_type; - } - - /** - * The storage type for this volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.StorageType storage_type = 2; - * @param int $var - * @return $this - */ - public function setStorageType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Volume\StorageType::class); - $this->storage_type = $var; - - return $this; - } - - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.State state = 3; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of this storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.State state = 3; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Volume\State::class); - $this->state = $var; - - return $this; - } - - /** - * The requested size of this storage volume, in GiB. - * - * Generated from protobuf field int64 requested_size_gib = 4; - * @return int|string - */ - public function getRequestedSizeGib() - { - return $this->requested_size_gib; - } - - /** - * The requested size of this storage volume, in GiB. - * - * Generated from protobuf field int64 requested_size_gib = 4; - * @param int|string $var - * @return $this - */ - public function setRequestedSizeGib($var) - { - GPBUtil::checkInt64($var); - $this->requested_size_gib = $var; - - return $this; - } - - /** - * The current size of this storage volume, in GiB, including space reserved - * for snapshots. This size might be different than the requested size if the - * storage volume has been configured with auto grow or auto shrink. - * - * Generated from protobuf field int64 current_size_gib = 5; - * @return int|string - */ - public function getCurrentSizeGib() - { - return $this->current_size_gib; - } - - /** - * The current size of this storage volume, in GiB, including space reserved - * for snapshots. This size might be different than the requested size if the - * storage volume has been configured with auto grow or auto shrink. - * - * Generated from protobuf field int64 current_size_gib = 5; - * @param int|string $var - * @return $this - */ - public function setCurrentSizeGib($var) - { - GPBUtil::checkInt64($var); - $this->current_size_gib = $var; - - return $this; - } - - /** - * Additional emergency size that was requested for this Volume, in GiB. - * current_size_gib includes this value. - * - * Generated from protobuf field int64 emergency_size_gib = 14; - * @return int|string - */ - public function getEmergencySizeGib() - { - return $this->emergency_size_gib; - } - - /** - * Additional emergency size that was requested for this Volume, in GiB. - * current_size_gib includes this value. - * - * Generated from protobuf field int64 emergency_size_gib = 14; - * @param int|string $var - * @return $this - */ - public function setEmergencySizeGib($var) - { - GPBUtil::checkInt64($var); - $this->emergency_size_gib = $var; - - return $this; - } - - /** - * The size, in GiB, that this storage volume has expanded as a result of an - * auto grow policy. In the absence of auto-grow, the value is 0. - * - * Generated from protobuf field int64 auto_grown_size_gib = 6; - * @return int|string - */ - public function getAutoGrownSizeGib() - { - return $this->auto_grown_size_gib; - } - - /** - * The size, in GiB, that this storage volume has expanded as a result of an - * auto grow policy. In the absence of auto-grow, the value is 0. - * - * Generated from protobuf field int64 auto_grown_size_gib = 6; - * @param int|string $var - * @return $this - */ - public function setAutoGrownSizeGib($var) - { - GPBUtil::checkInt64($var); - $this->auto_grown_size_gib = $var; - - return $this; - } - - /** - * The space remaining in the storage volume for new LUNs, in GiB, excluding - * space reserved for snapshots. - * - * Generated from protobuf field int64 remaining_space_gib = 7; - * @return int|string - */ - public function getRemainingSpaceGib() - { - return $this->remaining_space_gib; - } - - /** - * The space remaining in the storage volume for new LUNs, in GiB, excluding - * space reserved for snapshots. - * - * Generated from protobuf field int64 remaining_space_gib = 7; - * @param int|string $var - * @return $this - */ - public function setRemainingSpaceGib($var) - { - GPBUtil::checkInt64($var); - $this->remaining_space_gib = $var; - - return $this; - } - - /** - * Details about snapshot space reservation and usage on the storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotReservationDetail snapshot_reservation_detail = 8; - * @return \Google\Cloud\BareMetalSolution\V2\Volume\SnapshotReservationDetail|null - */ - public function getSnapshotReservationDetail() - { - return $this->snapshot_reservation_detail; - } - - public function hasSnapshotReservationDetail() - { - return isset($this->snapshot_reservation_detail); - } - - public function clearSnapshotReservationDetail() - { - unset($this->snapshot_reservation_detail); - } - - /** - * Details about snapshot space reservation and usage on the storage volume. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotReservationDetail snapshot_reservation_detail = 8; - * @param \Google\Cloud\BareMetalSolution\V2\Volume\SnapshotReservationDetail $var - * @return $this - */ - public function setSnapshotReservationDetail($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\Volume\SnapshotReservationDetail::class); - $this->snapshot_reservation_detail = $var; - - return $this; - } - - /** - * The behavior to use when snapshot reserved space is full. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotAutoDeleteBehavior snapshot_auto_delete_behavior = 9; - * @return int - */ - public function getSnapshotAutoDeleteBehavior() - { - return $this->snapshot_auto_delete_behavior; - } - - /** - * The behavior to use when snapshot reserved space is full. - * - * Generated from protobuf field .google.cloud.baremetalsolution.v2.Volume.SnapshotAutoDeleteBehavior snapshot_auto_delete_behavior = 9; - * @param int $var - * @return $this - */ - public function setSnapshotAutoDeleteBehavior($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BareMetalSolution\V2\Volume\SnapshotAutoDeleteBehavior::class); - $this->snapshot_auto_delete_behavior = $var; - - return $this; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 12; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 12; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Whether snapshots are enabled. - * - * Generated from protobuf field bool snapshot_enabled = 13; - * @return bool - */ - public function getSnapshotEnabled() - { - return $this->snapshot_enabled; - } - - /** - * Whether snapshots are enabled. - * - * Generated from protobuf field bool snapshot_enabled = 13; - * @param bool $var - * @return $this - */ - public function setSnapshotEnabled($var) - { - GPBUtil::checkBool($var); - $this->snapshot_enabled = $var; - - return $this; - } - - /** - * Immutable. Pod name. - * - * Generated from protobuf field string pod = 15 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getPod() - { - return $this->pod; - } - - /** - * Immutable. Pod name. - * - * Generated from protobuf field string pod = 15 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setPod($var) - { - GPBUtil::checkString($var, True); - $this->pod = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotAutoDeleteBehavior.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotAutoDeleteBehavior.php deleted file mode 100644 index c00ae75623da..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotAutoDeleteBehavior.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.baremetalsolution.v2.Volume.SnapshotAutoDeleteBehavior - */ -class SnapshotAutoDeleteBehavior -{ - /** - * The unspecified behavior. - * - * Generated from protobuf enum SNAPSHOT_AUTO_DELETE_BEHAVIOR_UNSPECIFIED = 0; - */ - const SNAPSHOT_AUTO_DELETE_BEHAVIOR_UNSPECIFIED = 0; - /** - * Don't delete any snapshots. This disables new snapshot creation, as - * long as the snapshot reserved space is full. - * - * Generated from protobuf enum DISABLED = 1; - */ - const DISABLED = 1; - /** - * Delete the oldest snapshots first. - * - * Generated from protobuf enum OLDEST_FIRST = 2; - */ - const OLDEST_FIRST = 2; - /** - * Delete the newest snapshots first. - * - * Generated from protobuf enum NEWEST_FIRST = 3; - */ - const NEWEST_FIRST = 3; - - private static $valueToName = [ - self::SNAPSHOT_AUTO_DELETE_BEHAVIOR_UNSPECIFIED => 'SNAPSHOT_AUTO_DELETE_BEHAVIOR_UNSPECIFIED', - self::DISABLED => 'DISABLED', - self::OLDEST_FIRST => 'OLDEST_FIRST', - self::NEWEST_FIRST => 'NEWEST_FIRST', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SnapshotAutoDeleteBehavior::class, \Google\Cloud\BareMetalSolution\V2\Volume_SnapshotAutoDeleteBehavior::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotReservationDetail.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotReservationDetail.php deleted file mode 100644 index 16739fe08920..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/SnapshotReservationDetail.php +++ /dev/null @@ -1,204 +0,0 @@ -google.cloud.baremetalsolution.v2.Volume.SnapshotReservationDetail - */ -class SnapshotReservationDetail extends \Google\Protobuf\Internal\Message -{ - /** - * The space on this storage volume reserved for snapshots, shown in GiB. - * - * Generated from protobuf field int64 reserved_space_gib = 1; - */ - protected $reserved_space_gib = 0; - /** - * The percent of snapshot space on this storage volume actually being used - * by the snapshot copies. This value might be higher than 100% if the - * snapshot copies have overflowed into the data portion of the storage - * volume. - * - * Generated from protobuf field int32 reserved_space_used_percent = 2; - */ - protected $reserved_space_used_percent = 0; - /** - * The amount, in GiB, of available space in this storage volume's reserved - * snapshot space. - * - * Generated from protobuf field int64 reserved_space_remaining_gib = 3; - */ - protected $reserved_space_remaining_gib = 0; - /** - * Percent of the total Volume size reserved for snapshot copies. - * Enabling snapshots requires reserving 20% or more of - * the storage volume space for snapshots. Maximum reserved space for - * snapshots is 40%. - * Setting this field will effectively set snapshot_enabled to true. - * - * Generated from protobuf field int32 reserved_space_percent = 4; - */ - protected $reserved_space_percent = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $reserved_space_gib - * The space on this storage volume reserved for snapshots, shown in GiB. - * @type int $reserved_space_used_percent - * The percent of snapshot space on this storage volume actually being used - * by the snapshot copies. This value might be higher than 100% if the - * snapshot copies have overflowed into the data portion of the storage - * volume. - * @type int|string $reserved_space_remaining_gib - * The amount, in GiB, of available space in this storage volume's reserved - * snapshot space. - * @type int $reserved_space_percent - * Percent of the total Volume size reserved for snapshot copies. - * Enabling snapshots requires reserving 20% or more of - * the storage volume space for snapshots. Maximum reserved space for - * snapshots is 40%. - * Setting this field will effectively set snapshot_enabled to true. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Baremetalsolution\V2\Volume::initOnce(); - parent::__construct($data); - } - - /** - * The space on this storage volume reserved for snapshots, shown in GiB. - * - * Generated from protobuf field int64 reserved_space_gib = 1; - * @return int|string - */ - public function getReservedSpaceGib() - { - return $this->reserved_space_gib; - } - - /** - * The space on this storage volume reserved for snapshots, shown in GiB. - * - * Generated from protobuf field int64 reserved_space_gib = 1; - * @param int|string $var - * @return $this - */ - public function setReservedSpaceGib($var) - { - GPBUtil::checkInt64($var); - $this->reserved_space_gib = $var; - - return $this; - } - - /** - * The percent of snapshot space on this storage volume actually being used - * by the snapshot copies. This value might be higher than 100% if the - * snapshot copies have overflowed into the data portion of the storage - * volume. - * - * Generated from protobuf field int32 reserved_space_used_percent = 2; - * @return int - */ - public function getReservedSpaceUsedPercent() - { - return $this->reserved_space_used_percent; - } - - /** - * The percent of snapshot space on this storage volume actually being used - * by the snapshot copies. This value might be higher than 100% if the - * snapshot copies have overflowed into the data portion of the storage - * volume. - * - * Generated from protobuf field int32 reserved_space_used_percent = 2; - * @param int $var - * @return $this - */ - public function setReservedSpaceUsedPercent($var) - { - GPBUtil::checkInt32($var); - $this->reserved_space_used_percent = $var; - - return $this; - } - - /** - * The amount, in GiB, of available space in this storage volume's reserved - * snapshot space. - * - * Generated from protobuf field int64 reserved_space_remaining_gib = 3; - * @return int|string - */ - public function getReservedSpaceRemainingGib() - { - return $this->reserved_space_remaining_gib; - } - - /** - * The amount, in GiB, of available space in this storage volume's reserved - * snapshot space. - * - * Generated from protobuf field int64 reserved_space_remaining_gib = 3; - * @param int|string $var - * @return $this - */ - public function setReservedSpaceRemainingGib($var) - { - GPBUtil::checkInt64($var); - $this->reserved_space_remaining_gib = $var; - - return $this; - } - - /** - * Percent of the total Volume size reserved for snapshot copies. - * Enabling snapshots requires reserving 20% or more of - * the storage volume space for snapshots. Maximum reserved space for - * snapshots is 40%. - * Setting this field will effectively set snapshot_enabled to true. - * - * Generated from protobuf field int32 reserved_space_percent = 4; - * @return int - */ - public function getReservedSpacePercent() - { - return $this->reserved_space_percent; - } - - /** - * Percent of the total Volume size reserved for snapshot copies. - * Enabling snapshots requires reserving 20% or more of - * the storage volume space for snapshots. Maximum reserved space for - * snapshots is 40%. - * Setting this field will effectively set snapshot_enabled to true. - * - * Generated from protobuf field int32 reserved_space_percent = 4; - * @param int $var - * @return $this - */ - public function setReservedSpacePercent($var) - { - GPBUtil::checkInt32($var); - $this->reserved_space_percent = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SnapshotReservationDetail::class, \Google\Cloud\BareMetalSolution\V2\Volume_SnapshotReservationDetail::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/State.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/State.php deleted file mode 100644 index 8ac88903ab81..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/State.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.baremetalsolution.v2.Volume.State - */ -class State -{ - /** - * The storage volume is in an unknown state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The storage volume is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The storage volume is ready for use. - * - * Generated from protobuf enum READY = 2; - */ - const READY = 2; - /** - * The storage volume has been requested to be deleted. - * - * Generated from protobuf enum DELETING = 3; - */ - const DELETING = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::READY => 'READY', - self::DELETING => 'DELETING', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BareMetalSolution\V2\Volume_State::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/StorageType.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/StorageType.php deleted file mode 100644 index 2ccb93087f78..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume/StorageType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.baremetalsolution.v2.Volume.StorageType - */ -class StorageType -{ - /** - * The storage type for this volume is unknown. - * - * Generated from protobuf enum STORAGE_TYPE_UNSPECIFIED = 0; - */ - const STORAGE_TYPE_UNSPECIFIED = 0; - /** - * The storage type for this volume is SSD. - * - * Generated from protobuf enum SSD = 1; - */ - const SSD = 1; - /** - * This storage type for this volume is HDD. - * - * Generated from protobuf enum HDD = 2; - */ - const HDD = 2; - - private static $valueToName = [ - self::STORAGE_TYPE_UNSPECIFIED => 'STORAGE_TYPE_UNSPECIFIED', - self::SSD => 'SSD', - self::HDD => 'HDD', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StorageType::class, \Google\Cloud\BareMetalSolution\V2\Volume_StorageType::class); - diff --git a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_SnapshotAutoDeleteBehavior.php b/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_SnapshotAutoDeleteBehavior.php deleted file mode 100644 index 86429c5137da..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/proto/src/Google/Cloud/BareMetalSolution/V2/Volume_SnapshotAutoDeleteBehavior.php +++ /dev/null @@ -1,16 +0,0 @@ -setInstance($formattedInstance) - ->setLun($formattedLun); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->detachLun($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 -{ - $formattedInstance = BareMetalSolutionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $formattedLun = BareMetalSolutionClient::lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - - detach_lun_sample($formattedInstance, $formattedLun); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_DetachLun_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_instance.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_instance.php deleted file mode 100644 index 309194656d8d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_instance.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Instance $response */ - $response = $bareMetalSolutionClient->getInstance($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 = BareMetalSolutionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - get_instance_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_GetInstance_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_lun.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_lun.php deleted file mode 100644 index 3a525842f4e2..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_lun.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Lun $response */ - $response = $bareMetalSolutionClient->getLun($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 = BareMetalSolutionClient::lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - - get_lun_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_GetLun_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_network.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_network.php deleted file mode 100644 index 5031d96af37d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_network.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Network $response */ - $response = $bareMetalSolutionClient->getNetwork($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 = BareMetalSolutionClient::networkName('[PROJECT]', '[LOCATION]', '[NETWORK]'); - - get_network_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_GetNetwork_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_nfs_share.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_nfs_share.php deleted file mode 100644 index aa4541d111dc..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_nfs_share.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NfsShare $response */ - $response = $bareMetalSolutionClient->getNfsShare($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 = BareMetalSolutionClient::nFSShareName('[PROJECT]', '[LOCATION]', '[NFS_SHARE]'); - - get_nfs_share_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_GetNfsShare_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_volume.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_volume.php deleted file mode 100644 index a36c1522bdc0..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/get_volume.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Volume $response */ - $response = $bareMetalSolutionClient->getVolume($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 = BareMetalSolutionClient::volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - - get_volume_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_GetVolume_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_instances.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_instances.php deleted file mode 100644 index 49839079f1aa..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_instances.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listInstances($request); - - /** @var Instance $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 = BareMetalSolutionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_instances_sample($formattedParent); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListInstances_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_luns.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_luns.php deleted file mode 100644 index 2e6c6651c43a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_luns.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listLuns($request); - - /** @var Lun $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 = BareMetalSolutionClient::volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - - list_luns_sample($formattedParent); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListLuns_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_network_usage.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_network_usage.php deleted file mode 100644 index afa319e928dc..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_network_usage.php +++ /dev/null @@ -1,72 +0,0 @@ -setLocation($formattedLocation); - - // Call the API and handle any network failures. - try { - /** @var ListNetworkUsageResponse $response */ - $response = $bareMetalSolutionClient->listNetworkUsage($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 -{ - $formattedLocation = BareMetalSolutionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_network_usage_sample($formattedLocation); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListNetworkUsage_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_networks.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_networks.php deleted file mode 100644 index 946d279a482f..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_networks.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listNetworks($request); - - /** @var Network $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 = BareMetalSolutionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_networks_sample($formattedParent); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListNetworks_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_nfs_shares.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_nfs_shares.php deleted file mode 100644 index a8cdd1a2b362..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_nfs_shares.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listNfsShares($request); - - /** @var NfsShare $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 = BareMetalSolutionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_nfs_shares_sample($formattedParent); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListNfsShares_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_volumes.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_volumes.php deleted file mode 100644 index f4d071a1f2b1..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/list_volumes.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $bareMetalSolutionClient->listVolumes($request); - - /** @var Volume $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 = BareMetalSolutionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_volumes_sample($formattedParent); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ListVolumes_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/reset_instance.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/reset_instance.php deleted file mode 100644 index abf5c0d3ad6d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/reset_instance.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->resetInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ResetInstanceResponse $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 = BareMetalSolutionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - reset_instance_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ResetInstance_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/resize_volume.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/resize_volume.php deleted file mode 100644 index a07f7f7b4a29..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/resize_volume.php +++ /dev/null @@ -1,83 +0,0 @@ -setVolume($formattedVolume); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->resizeVolume($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Volume $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 -{ - $formattedVolume = BareMetalSolutionClient::volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - - resize_volume_sample($formattedVolume); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_ResizeVolume_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/start_instance.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/start_instance.php deleted file mode 100644 index 1082e8499ab7..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/start_instance.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->startInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var StartInstanceResponse $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 = BareMetalSolutionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - start_instance_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_StartInstance_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/stop_instance.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/stop_instance.php deleted file mode 100644 index 959adec98dda..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/stop_instance.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->stopInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var StopInstanceResponse $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 = BareMetalSolutionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - stop_instance_sample($formattedName); -} -// [END baremetalsolution_v2_generated_BareMetalSolution_StopInstance_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_instance.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_instance.php deleted file mode 100644 index be9f92b1e75b..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_instance.php +++ /dev/null @@ -1,71 +0,0 @@ -setInstance($instance); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 baremetalsolution_v2_generated_BareMetalSolution_UpdateInstance_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_network.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_network.php deleted file mode 100644 index 8c0c8ddb0c6f..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_network.php +++ /dev/null @@ -1,71 +0,0 @@ -setNetwork($network); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateNetwork($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Network $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 baremetalsolution_v2_generated_BareMetalSolution_UpdateNetwork_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_nfs_share.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_nfs_share.php deleted file mode 100644 index 07f13029fa7a..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_nfs_share.php +++ /dev/null @@ -1,71 +0,0 @@ -setNfsShare($nfsShare); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateNfsShare($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var NfsShare $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 baremetalsolution_v2_generated_BareMetalSolution_UpdateNfsShare_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_volume.php b/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_volume.php deleted file mode 100644 index 31982a16b76d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/samples/V2/BareMetalSolutionClient/update_volume.php +++ /dev/null @@ -1,71 +0,0 @@ -setVolume($volume); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $bareMetalSolutionClient->updateVolume($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Volume $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 baremetalsolution_v2_generated_BareMetalSolution_UpdateVolume_sync] diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/BareMetalSolutionClient.php b/owl-bot-staging/BareMetalSolution/v2/src/V2/BareMetalSolutionClient.php deleted file mode 100644 index d49859a08859..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/src/V2/BareMetalSolutionClient.php +++ /dev/null @@ -1,34 +0,0 @@ -instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $formattedLun = $bareMetalSolutionClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - * $operationResponse = $bareMetalSolutionClient->detachLun($formattedInstance, $formattedLun); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->detachLun($formattedInstance, $formattedLun); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'detachLun'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * 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. - */ -class BareMetalSolutionGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.baremetalsolution.v2.BareMetalSolution'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'baremetalsolution.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $instanceNameTemplate; - - private static $locationNameTemplate; - - private static $lunNameTemplate; - - private static $nFSShareNameTemplate; - - private static $networkNameTemplate; - - private static $serverNetworkTemplateNameTemplate; - - private static $volumeNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/bare_metal_solution_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/bare_metal_solution_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/bare_metal_solution_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/bare_metal_solution_rest_client_config.php', - ], - ], - ]; - } - - private static function getInstanceNameTemplate() - { - if (self::$instanceNameTemplate == null) { - self::$instanceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/instances/{instance}'); - } - - return self::$instanceNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getLunNameTemplate() - { - if (self::$lunNameTemplate == null) { - self::$lunNameTemplate = new PathTemplate('projects/{project}/locations/{location}/volumes/{volume}/luns/{lun}'); - } - - return self::$lunNameTemplate; - } - - private static function getNFSShareNameTemplate() - { - if (self::$nFSShareNameTemplate == null) { - self::$nFSShareNameTemplate = new PathTemplate('projects/{project}/locations/{location}/nfsShares/{nfs_share}'); - } - - return self::$nFSShareNameTemplate; - } - - private static function getNetworkNameTemplate() - { - if (self::$networkNameTemplate == null) { - self::$networkNameTemplate = new PathTemplate('projects/{project}/locations/{location}/networks/{network}'); - } - - return self::$networkNameTemplate; - } - - private static function getServerNetworkTemplateNameTemplate() - { - if (self::$serverNetworkTemplateNameTemplate == null) { - self::$serverNetworkTemplateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}'); - } - - return self::$serverNetworkTemplateNameTemplate; - } - - private static function getVolumeNameTemplate() - { - if (self::$volumeNameTemplate == null) { - self::$volumeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/volumes/{volume}'); - } - - return self::$volumeNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'instance' => self::getInstanceNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'lun' => self::getLunNameTemplate(), - 'nFSShare' => self::getNFSShareNameTemplate(), - 'network' => self::getNetworkNameTemplate(), - 'serverNetworkTemplate' => self::getServerNetworkTemplateNameTemplate(), - 'volume' => self::getVolumeNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a instance - * resource. - * - * @param string $project - * @param string $location - * @param string $instance - * - * @return string The formatted instance resource. - */ - public static function instanceName($project, $location, $instance) - { - return self::getInstanceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'instance' => $instance, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a lun - * resource. - * - * @param string $project - * @param string $location - * @param string $volume - * @param string $lun - * - * @return string The formatted lun resource. - */ - public static function lunName($project, $location, $volume, $lun) - { - return self::getLunNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'volume' => $volume, - 'lun' => $lun, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a nfs_share - * resource. - * - * @param string $project - * @param string $location - * @param string $nfsShare - * - * @return string The formatted nfs_share resource. - */ - public static function nFSShareName($project, $location, $nfsShare) - { - return self::getNFSShareNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'nfs_share' => $nfsShare, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a network - * resource. - * - * @param string $project - * @param string $location - * @param string $network - * - * @return string The formatted network resource. - */ - public static function networkName($project, $location, $network) - { - return self::getNetworkNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'network' => $network, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * server_network_template resource. - * - * @param string $project - * @param string $location - * @param string $serverNetworkTemplate - * - * @return string The formatted server_network_template resource. - */ - public static function serverNetworkTemplateName($project, $location, $serverNetworkTemplate) - { - return self::getServerNetworkTemplateNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'server_network_template' => $serverNetworkTemplate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a volume - * resource. - * - * @param string $project - * @param string $location - * @param string $volume - * - * @return string The formatted volume resource. - */ - public static function volumeName($project, $location, $volume) - { - return self::getVolumeNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'volume' => $volume, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - instance: projects/{project}/locations/{location}/instances/{instance} - * - location: projects/{project}/locations/{location} - * - lun: projects/{project}/locations/{location}/volumes/{volume}/luns/{lun} - * - nFSShare: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * - network: projects/{project}/locations/{location}/networks/{network} - * - serverNetworkTemplate: projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template} - * - volume: projects/{project}/locations/{location}/volumes/{volume} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'baremetalsolution.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Detach LUN from Instance. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedInstance = $bareMetalSolutionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $formattedLun = $bareMetalSolutionClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - * $operationResponse = $bareMetalSolutionClient->detachLun($formattedInstance, $formattedLun); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->detachLun($formattedInstance, $formattedLun); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'detachLun'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $instance Required. Name of the instance. - * @param string $lun Required. Name of the Lun to detach. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function detachLun($instance, $lun, array $optionalArgs = []) - { - $request = new DetachLunRequest(); - $requestParamHeaders = []; - $request->setInstance($instance); - $request->setLun($lun); - $requestParamHeaders['instance'] = $instance; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DetachLun', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Get details about a single server. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $response = $bareMetalSolutionClient->getInstance($formattedName); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\Instance - * - * @throws ApiException if the remote call fails - */ - public function getInstance($name, array $optionalArgs = []) - { - $request = new GetInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetInstance', Instance::class, $optionalArgs, $request)->wait(); - } - - /** - * Get details of a single storage logical unit number(LUN). - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - * $response = $bareMetalSolutionClient->getLun($formattedName); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\Lun - * - * @throws ApiException if the remote call fails - */ - public function getLun($name, array $optionalArgs = []) - { - $request = new GetLunRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLun', Lun::class, $optionalArgs, $request)->wait(); - } - - /** - * Get details of a single network. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->networkName('[PROJECT]', '[LOCATION]', '[NETWORK]'); - * $response = $bareMetalSolutionClient->getNetwork($formattedName); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\Network - * - * @throws ApiException if the remote call fails - */ - public function getNetwork($name, array $optionalArgs = []) - { - $request = new GetNetworkRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetNetwork', Network::class, $optionalArgs, $request)->wait(); - } - - /** - * Get details of a single NFS share. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->nFSShareName('[PROJECT]', '[LOCATION]', '[NFS_SHARE]'); - * $response = $bareMetalSolutionClient->getNfsShare($formattedName); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\NfsShare - * - * @throws ApiException if the remote call fails - */ - public function getNfsShare($name, array $optionalArgs = []) - { - $request = new GetNfsShareRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetNfsShare', NfsShare::class, $optionalArgs, $request)->wait(); - } - - /** - * Get details of a single storage volume. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - * $response = $bareMetalSolutionClient->getVolume($formattedName); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\Volume - * - * @throws ApiException if the remote call fails - */ - public function getVolume($name, array $optionalArgs = []) - { - $request = new GetVolumeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetVolume', Volume::class, $optionalArgs, $request)->wait(); - } - - /** - * List servers in a given project and location. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedParent = $bareMetalSolutionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $bareMetalSolutionClient->listInstances($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $bareMetalSolutionClient->listInstances($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListInstancesRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * List filter. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listInstances($parent, array $optionalArgs = []) - { - $request = new ListInstancesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListInstances', $optionalArgs, ListInstancesResponse::class, $request); - } - - /** - * List storage volume luns for given storage volume. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedParent = $bareMetalSolutionClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - * // Iterate over pages of elements - * $pagedResponse = $bareMetalSolutionClient->listLuns($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $bareMetalSolutionClient->listLuns($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListLunsRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLuns($parent, array $optionalArgs = []) - { - $request = new ListLunsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLuns', $optionalArgs, ListLunsResponse::class, $request); - } - - /** - * List all Networks (and used IPs for each Network) in the vendor account - * associated with the specified project. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedLocation = $bareMetalSolutionClient->locationName('[PROJECT]', '[LOCATION]'); - * $response = $bareMetalSolutionClient->listNetworkUsage($formattedLocation); - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $location Required. Parent value (project and location). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BareMetalSolution\V2\ListNetworkUsageResponse - * - * @throws ApiException if the remote call fails - */ - public function listNetworkUsage($location, array $optionalArgs = []) - { - $request = new ListNetworkUsageRequest(); - $requestParamHeaders = []; - $request->setLocation($location); - $requestParamHeaders['location'] = $location; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('ListNetworkUsage', ListNetworkUsageResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * List network in a given project and location. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedParent = $bareMetalSolutionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $bareMetalSolutionClient->listNetworks($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $bareMetalSolutionClient->listNetworks($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListNetworksRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * List filter. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listNetworks($parent, array $optionalArgs = []) - { - $request = new ListNetworksRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNetworks', $optionalArgs, ListNetworksResponse::class, $request); - } - - /** - * List NFS shares. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedParent = $bareMetalSolutionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $bareMetalSolutionClient->listNfsShares($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $bareMetalSolutionClient->listNfsShares($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListNfsSharesRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * List filter. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listNfsShares($parent, array $optionalArgs = []) - { - $request = new ListNfsSharesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNfsShares', $optionalArgs, ListNfsSharesResponse::class, $request); - } - - /** - * List storage volumes in a given project and location. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedParent = $bareMetalSolutionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $bareMetalSolutionClient->listVolumes($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $bareMetalSolutionClient->listVolumes($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListVolumesRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * List filter. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listVolumes($parent, array $optionalArgs = []) - { - $request = new ListVolumesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListVolumes', $optionalArgs, ListVolumesResponse::class, $request); - } - - /** - * Perform an ungraceful, hard reset on a server. Equivalent to shutting the - * power off and then turning it back on. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $bareMetalSolutionClient->resetInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->resetInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'resetInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function resetInstance($name, array $optionalArgs = []) - { - $request = new ResetInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('ResetInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Emergency Volume resize. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedVolume = $bareMetalSolutionClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - * $operationResponse = $bareMetalSolutionClient->resizeVolume($formattedVolume); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->resizeVolume($formattedVolume); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'resizeVolume'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $volume Required. Volume to resize. - * @param array $optionalArgs { - * Optional. - * - * @type int $sizeGib - * New Volume size, in GiB. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function resizeVolume($volume, array $optionalArgs = []) - { - $request = new ResizeVolumeRequest(); - $requestParamHeaders = []; - $request->setVolume($volume); - $requestParamHeaders['volume'] = $volume; - if (isset($optionalArgs['sizeGib'])) { - $request->setSizeGib($optionalArgs['sizeGib']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('ResizeVolume', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Starts a server that was shutdown. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $bareMetalSolutionClient->startInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->startInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'startInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function startInstance($name, array $optionalArgs = []) - { - $request = new StartInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('StartInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Stop a running server. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $formattedName = $bareMetalSolutionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $bareMetalSolutionClient->stopInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->stopInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'stopInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function stopInstance($name, array $optionalArgs = []) - { - $request = new StopInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('StopInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Update details of a single server. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $instance = new Instance(); - * $operationResponse = $bareMetalSolutionClient->updateInstance($instance); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->updateInstance($instance); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'updateInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param Instance $instance Required. The server to update. - * - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/instances/{instance} - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. - * The currently supported fields are: - * `labels` - * `hyperthreading_enabled` - * `os_image` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateInstance($instance, array $optionalArgs = []) - { - $request = new UpdateInstanceRequest(); - $requestParamHeaders = []; - $request->setInstance($instance); - $requestParamHeaders['instance.name'] = $instance->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Update details of a single network. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $network = new Network(); - * $operationResponse = $bareMetalSolutionClient->updateNetwork($network); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->updateNetwork($network); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'updateNetwork'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param Network $network Required. The network to update. - * - * The `name` field is used to identify the instance to update. - * Format: projects/{project}/locations/{location}/networks/{network} - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. - * The only currently supported fields are: - * `labels`, `reservations` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateNetwork($network, array $optionalArgs = []) - { - $request = new UpdateNetworkRequest(); - $requestParamHeaders = []; - $request->setNetwork($network); - $requestParamHeaders['network.name'] = $network->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateNetwork', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Update details of a single NFS share. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $nfsShare = new NfsShare(); - * $operationResponse = $bareMetalSolutionClient->updateNfsShare($nfsShare); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->updateNfsShare($nfsShare); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'updateNfsShare'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param NfsShare $nfsShare Required. The NFS share to update. - * - * The `name` field is used to identify the NFS share to update. - * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share} - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. - * The only currently supported fields are: - * `labels` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateNfsShare($nfsShare, array $optionalArgs = []) - { - $request = new UpdateNfsShareRequest(); - $requestParamHeaders = []; - $request->setNfsShare($nfsShare); - $requestParamHeaders['nfs_share.name'] = $nfsShare->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateNfsShare', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Update details of a single storage volume. - * - * Sample code: - * ``` - * $bareMetalSolutionClient = new BareMetalSolutionClient(); - * try { - * $volume = new Volume(); - * $operationResponse = $bareMetalSolutionClient->updateVolume($volume); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $bareMetalSolutionClient->updateVolume($volume); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $bareMetalSolutionClient->resumeOperation($operationName, 'updateVolume'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $bareMetalSolutionClient->close(); - * } - * ``` - * - * @param Volume $volume Required. The volume to update. - * - * The `name` field is used to identify the volume to update. - * Format: projects/{project}/locations/{location}/volumes/{volume} - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. - * The only currently supported fields are: - * `snapshot_auto_delete_behavior` - * `snapshot_schedule_policy_name` - * 'labels' - * 'snapshot_enabled' - * 'snapshot_reservation_detail.reserved_space_percent' - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateVolume($volume, array $optionalArgs = []) - { - $request = new UpdateVolumeRequest(); - $requestParamHeaders = []; - $request->setVolume($volume); - $requestParamHeaders['volume.name'] = $volume->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateVolume', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } -} diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/gapic_metadata.json b/owl-bot-staging/BareMetalSolution/v2/src/V2/gapic_metadata.json deleted file mode 100644 index 3e39f284bb08..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/src/V2/gapic_metadata.json +++ /dev/null @@ -1,118 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.baremetalsolution.v2", - "libraryPackage": "Google\\Cloud\\BareMetalSolution\\V2", - "services": { - "BareMetalSolution": { - "clients": { - "grpc": { - "libraryClient": "BareMetalSolutionGapicClient", - "rpcs": { - "DetachLun": { - "methods": [ - "detachLun" - ] - }, - "GetInstance": { - "methods": [ - "getInstance" - ] - }, - "GetLun": { - "methods": [ - "getLun" - ] - }, - "GetNetwork": { - "methods": [ - "getNetwork" - ] - }, - "GetNfsShare": { - "methods": [ - "getNfsShare" - ] - }, - "GetVolume": { - "methods": [ - "getVolume" - ] - }, - "ListInstances": { - "methods": [ - "listInstances" - ] - }, - "ListLuns": { - "methods": [ - "listLuns" - ] - }, - "ListNetworkUsage": { - "methods": [ - "listNetworkUsage" - ] - }, - "ListNetworks": { - "methods": [ - "listNetworks" - ] - }, - "ListNfsShares": { - "methods": [ - "listNfsShares" - ] - }, - "ListVolumes": { - "methods": [ - "listVolumes" - ] - }, - "ResetInstance": { - "methods": [ - "resetInstance" - ] - }, - "ResizeVolume": { - "methods": [ - "resizeVolume" - ] - }, - "StartInstance": { - "methods": [ - "startInstance" - ] - }, - "StopInstance": { - "methods": [ - "stopInstance" - ] - }, - "UpdateInstance": { - "methods": [ - "updateInstance" - ] - }, - "UpdateNetwork": { - "methods": [ - "updateNetwork" - ] - }, - "UpdateNfsShare": { - "methods": [ - "updateNfsShare" - ] - }, - "UpdateVolume": { - "methods": [ - "updateVolume" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_client_config.json b/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_client_config.json deleted file mode 100644 index 968329f31e6c..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_client_config.json +++ /dev/null @@ -1,132 +0,0 @@ -{ - "interfaces": { - "google.cloud.baremetalsolution.v2.BareMetalSolution": { - "retry_codes": { - "no_retry_codes": [], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "DetachLun": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetLun": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetNetwork": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetNfsShare": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetVolume": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListInstances": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListLuns": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListNetworkUsage": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListNetworks": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListNfsShares": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListVolumes": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ResetInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ResizeVolume": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "StartInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "StopInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateNetwork": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateNfsShare": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateVolume": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_descriptor_config.php b/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_descriptor_config.php deleted file mode 100644 index ba98f4d93a1d..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_descriptor_config.php +++ /dev/null @@ -1,364 +0,0 @@ - [ - 'google.cloud.baremetalsolution.v2.BareMetalSolution' => [ - 'DetachLun' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\Instance', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'instance', - 'fieldAccessors' => [ - 'getInstance', - ], - ], - ], - ], - 'ResetInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\ResetInstanceResponse', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ResizeVolume' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\Volume', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'volume', - 'fieldAccessors' => [ - 'getVolume', - ], - ], - ], - ], - 'StartInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\StartInstanceResponse', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'StopInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\StopInstanceResponse', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\Instance', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'instance.name', - 'fieldAccessors' => [ - 'getInstance', - 'getName', - ], - ], - ], - ], - 'UpdateNetwork' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\Network', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'network.name', - 'fieldAccessors' => [ - 'getNetwork', - 'getName', - ], - ], - ], - ], - 'UpdateNfsShare' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\NfsShare', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'nfs_share.name', - 'fieldAccessors' => [ - 'getNfsShare', - 'getName', - ], - ], - ], - ], - 'UpdateVolume' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BareMetalSolution\V2\Volume', - 'metadataReturnType' => '\Google\Cloud\BareMetalSolution\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'volume.name', - 'fieldAccessors' => [ - 'getVolume', - 'getName', - ], - ], - ], - ], - 'GetInstance' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Instance', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetLun' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Lun', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNetwork' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Network', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNfsShare' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\NfsShare', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetVolume' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\Volume', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListInstances' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getInstances', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListInstancesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListLuns' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLuns', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListLunsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkUsage' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNetworkUsageResponse', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getLocation', - ], - ], - ], - ], - 'ListNetworks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNetworks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNetworksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNfsShares' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNfsShares', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListNfsSharesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListVolumes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getVolumes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BareMetalSolution\V2\ListVolumesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'templateMap' => [ - 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', - 'location' => 'projects/{project}/locations/{location}', - 'lun' => 'projects/{project}/locations/{location}/volumes/{volume}/luns/{lun}', - 'nFSShare' => 'projects/{project}/locations/{location}/nfsShares/{nfs_share}', - 'network' => 'projects/{project}/locations/{location}/networks/{network}', - 'serverNetworkTemplate' => 'projects/{project}/locations/{location}/serverNetworkTemplate/{server_network_template}', - 'volume' => 'projects/{project}/locations/{location}/volumes/{volume}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_rest_client_config.php b/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_rest_client_config.php deleted file mode 100644 index 61d57779bbaa..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/src/V2/resources/bare_metal_solution_rest_client_config.php +++ /dev/null @@ -1,266 +0,0 @@ - [ - 'google.cloud.baremetalsolution.v2.BareMetalSolution' => [ - 'DetachLun' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{instance=projects/*/locations/*/instances/*}:detachLun', - 'body' => '*', - 'placeholders' => [ - 'instance' => [ - 'getters' => [ - 'getInstance', - ], - ], - ], - ], - 'GetInstance' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/instances/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetLun' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/volumes/*/luns/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNetwork' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/networks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNfsShare' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/nfsShares/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetVolume' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/volumes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListInstances' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/instances', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListLuns' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*/volumes/*}/luns', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkUsage' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{location=projects/*/locations/*}/networks:listNetworkUsage', - 'placeholders' => [ - 'location' => [ - 'getters' => [ - 'getLocation', - ], - ], - ], - ], - 'ListNetworks' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/networks', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNfsShares' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/nfsShares', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListVolumes' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/volumes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ResetInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/instances/*}:reset', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ResizeVolume' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{volume=projects/*/locations/*/volumes/*}:resize', - 'body' => '*', - 'placeholders' => [ - 'volume' => [ - 'getters' => [ - 'getVolume', - ], - ], - ], - ], - 'StartInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/instances/*}:start', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'StopInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/instances/*}:stop', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInstance' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{instance.name=projects/*/locations/*/instances/*}', - 'body' => 'instance', - 'placeholders' => [ - 'instance.name' => [ - 'getters' => [ - 'getInstance', - 'getName', - ], - ], - ], - ], - 'UpdateNetwork' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{network.name=projects/*/locations/*/networks/*}', - 'body' => 'network', - 'placeholders' => [ - 'network.name' => [ - 'getters' => [ - 'getNetwork', - 'getName', - ], - ], - ], - ], - 'UpdateNfsShare' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{nfs_share.name=projects/*/locations/*/nfsShares/*}', - 'body' => 'nfs_share', - 'placeholders' => [ - 'nfs_share.name' => [ - 'getters' => [ - 'getNfsShare', - 'getName', - ], - ], - ], - ], - 'UpdateVolume' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{volume.name=projects/*/locations/*/volumes/*}', - 'body' => 'volume', - 'placeholders' => [ - 'volume.name' => [ - 'getters' => [ - 'getVolume', - 'getName', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/BareMetalSolutionClientTest.php b/owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/BareMetalSolutionClientTest.php deleted file mode 100644 index 5fa577a907b2..000000000000 --- a/owl-bot-staging/BareMetalSolution/v2/tests/Unit/V2/BareMetalSolutionClientTest.php +++ /dev/null @@ -1,1975 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return BareMetalSolutionClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new BareMetalSolutionClient($options); - } - - /** @test */ - public function detachLunTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/detachLunTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $machineType = 'machineType1838323762'; - $hyperthreadingEnabled = true; - $interactiveSerialConsoleEnabled = false; - $osImage = 'osImage1982209856'; - $pod = 'pod111173'; - $networkTemplate = 'networkTemplate215365483'; - $expectedResponse = new Instance(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setMachineType($machineType); - $expectedResponse->setHyperthreadingEnabled($hyperthreadingEnabled); - $expectedResponse->setInteractiveSerialConsoleEnabled($interactiveSerialConsoleEnabled); - $expectedResponse->setOsImage($osImage); - $expectedResponse->setPod($pod); - $expectedResponse->setNetworkTemplate($networkTemplate); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/detachLunTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedInstance = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $formattedLun = $gapicClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - $response = $gapicClient->detachLun($formattedInstance, $formattedLun); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/DetachLun', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getInstance(); - $this->assertProtobufEquals($formattedInstance, $actualValue); - $actualValue = $actualApiRequestObject->getLun(); - $this->assertProtobufEquals($formattedLun, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/detachLunTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function detachLunExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/detachLunTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedInstance = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $formattedLun = $gapicClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - $response = $gapicClient->detachLun($formattedInstance, $formattedLun); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/detachLunTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getInstanceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $machineType = 'machineType1838323762'; - $hyperthreadingEnabled = true; - $interactiveSerialConsoleEnabled = false; - $osImage = 'osImage1982209856'; - $pod = 'pod111173'; - $networkTemplate = 'networkTemplate215365483'; - $expectedResponse = new Instance(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setMachineType($machineType); - $expectedResponse->setHyperthreadingEnabled($hyperthreadingEnabled); - $expectedResponse->setInteractiveSerialConsoleEnabled($interactiveSerialConsoleEnabled); - $expectedResponse->setOsImage($osImage); - $expectedResponse->setPod($pod); - $expectedResponse->setNetworkTemplate($networkTemplate); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->getInstance($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetInstance', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getInstanceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - try { - $gapicClient->getInstance($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLunTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $sizeGb = 2105542105; - $storageVolume = 'storageVolume-768806562'; - $shareable = false; - $bootLun = true; - $wwid = 'wwid3662843'; - $expectedResponse = new Lun(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setSizeGb($sizeGb); - $expectedResponse->setStorageVolume($storageVolume); - $expectedResponse->setShareable($shareable); - $expectedResponse->setBootLun($bootLun); - $expectedResponse->setWwid($wwid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - $response = $gapicClient->getLun($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetLun', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLunExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->lunName('[PROJECT]', '[LOCATION]', '[VOLUME]', '[LUN]'); - try { - $gapicClient->getLun($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNetworkTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $ipAddress = 'ipAddress1480014044'; - $vlanId = 'vlanId536153463'; - $cidr = 'cidr3053428'; - $servicesCidr = 'servicesCidr-1169831243'; - $expectedResponse = new Network(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setIpAddress($ipAddress); - $expectedResponse->setVlanId($vlanId); - $expectedResponse->setCidr($cidr); - $expectedResponse->setServicesCidr($servicesCidr); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->networkName('[PROJECT]', '[LOCATION]', '[NETWORK]'); - $response = $gapicClient->getNetwork($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetNetwork', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNetworkExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->networkName('[PROJECT]', '[LOCATION]', '[NETWORK]'); - try { - $gapicClient->getNetwork($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNfsShareTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $nfsShareId = 'nfsShareId931294079'; - $volume = 'volume-810883302'; - $expectedResponse = new NfsShare(); - $expectedResponse->setName($name2); - $expectedResponse->setNfsShareId($nfsShareId); - $expectedResponse->setVolume($volume); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->nFSShareName('[PROJECT]', '[LOCATION]', '[NFS_SHARE]'); - $response = $gapicClient->getNfsShare($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetNfsShare', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNfsShareExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->nFSShareName('[PROJECT]', '[LOCATION]', '[NFS_SHARE]'); - try { - $gapicClient->getNfsShare($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getVolumeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $requestedSizeGib = 525454387; - $currentSizeGib = 72696456; - $emergencySizeGib = 1936971120; - $autoGrownSizeGib = 1245638678; - $remainingSpaceGib = 1423108606; - $snapshotEnabled = true; - $pod = 'pod111173'; - $expectedResponse = new Volume(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setRequestedSizeGib($requestedSizeGib); - $expectedResponse->setCurrentSizeGib($currentSizeGib); - $expectedResponse->setEmergencySizeGib($emergencySizeGib); - $expectedResponse->setAutoGrownSizeGib($autoGrownSizeGib); - $expectedResponse->setRemainingSpaceGib($remainingSpaceGib); - $expectedResponse->setSnapshotEnabled($snapshotEnabled); - $expectedResponse->setPod($pod); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - $response = $gapicClient->getVolume($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/GetVolume', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getVolumeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - try { - $gapicClient->getVolume($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInstancesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $instancesElement = new Instance(); - $instances = [ - $instancesElement, - ]; - $expectedResponse = new ListInstancesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setInstances($instances); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listInstances($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getInstances()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListInstances', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInstancesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listInstances($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLunsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $lunsElement = new Lun(); - $luns = [ - $lunsElement, - ]; - $expectedResponse = new ListLunsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLuns($luns); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - $response = $gapicClient->listLuns($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLuns()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListLuns', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLunsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - try { - $gapicClient->listLuns($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworkUsageTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ListNetworkUsageResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedLocation = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listNetworkUsage($formattedLocation); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNetworkUsage', $actualFuncCall); - $actualValue = $actualRequestObject->getLocation(); - $this->assertProtobufEquals($formattedLocation, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworkUsageExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedLocation = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listNetworkUsage($formattedLocation); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $networksElement = new Network(); - $networks = [ - $networksElement, - ]; - $expectedResponse = new ListNetworksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNetworks($networks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listNetworks($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNetworks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNetworks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listNetworks($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNfsSharesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $nfsSharesElement = new NfsShare(); - $nfsShares = [ - $nfsSharesElement, - ]; - $expectedResponse = new ListNfsSharesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNfsShares($nfsShares); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listNfsShares($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNfsShares()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListNfsShares', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNfsSharesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listNfsShares($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listVolumesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $volumesElement = new Volume(); - $volumes = [ - $volumesElement, - ]; - $expectedResponse = new ListVolumesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setVolumes($volumes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listVolumes($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getVolumes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ListVolumes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listVolumesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listVolumes($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function resetInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/resetInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new ResetInstanceResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/resetInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->resetInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ResetInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function resetInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/resetInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->resetInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function resizeVolumeTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/resizeVolumeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $requestedSizeGib = 525454387; - $currentSizeGib = 72696456; - $emergencySizeGib = 1936971120; - $autoGrownSizeGib = 1245638678; - $remainingSpaceGib = 1423108606; - $snapshotEnabled = true; - $pod = 'pod111173'; - $expectedResponse = new Volume(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setRequestedSizeGib($requestedSizeGib); - $expectedResponse->setCurrentSizeGib($currentSizeGib); - $expectedResponse->setEmergencySizeGib($emergencySizeGib); - $expectedResponse->setAutoGrownSizeGib($autoGrownSizeGib); - $expectedResponse->setRemainingSpaceGib($remainingSpaceGib); - $expectedResponse->setSnapshotEnabled($snapshotEnabled); - $expectedResponse->setPod($pod); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/resizeVolumeTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedVolume = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - $response = $gapicClient->resizeVolume($formattedVolume); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/ResizeVolume', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getVolume(); - $this->assertProtobufEquals($formattedVolume, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resizeVolumeTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function resizeVolumeExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/resizeVolumeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedVolume = $gapicClient->volumeName('[PROJECT]', '[LOCATION]', '[VOLUME]'); - $response = $gapicClient->resizeVolume($formattedVolume); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resizeVolumeTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function startInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/startInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new StartInstanceResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/startInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->startInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/StartInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/startInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function startInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/startInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->startInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/startInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function stopInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/stopInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new StopInstanceResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/stopInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->stopInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/StopInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/stopInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function stopInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/stopInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->stopInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/stopInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $machineType = 'machineType1838323762'; - $hyperthreadingEnabled = true; - $interactiveSerialConsoleEnabled = false; - $osImage = 'osImage1982209856'; - $pod = 'pod111173'; - $networkTemplate = 'networkTemplate215365483'; - $expectedResponse = new Instance(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setMachineType($machineType); - $expectedResponse->setHyperthreadingEnabled($hyperthreadingEnabled); - $expectedResponse->setInteractiveSerialConsoleEnabled($interactiveSerialConsoleEnabled); - $expectedResponse->setOsImage($osImage); - $expectedResponse->setPod($pod); - $expectedResponse->setNetworkTemplate($networkTemplate); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $instance = new Instance(); - $response = $gapicClient->updateInstance($instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getInstance(); - $this->assertProtobufEquals($instance, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $instance = new Instance(); - $response = $gapicClient->updateInstance($instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateNetworkTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateNetworkTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $ipAddress = 'ipAddress1480014044'; - $vlanId = 'vlanId536153463'; - $cidr = 'cidr3053428'; - $servicesCidr = 'servicesCidr-1169831243'; - $expectedResponse = new Network(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setIpAddress($ipAddress); - $expectedResponse->setVlanId($vlanId); - $expectedResponse->setCidr($cidr); - $expectedResponse->setServicesCidr($servicesCidr); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateNetworkTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $network = new Network(); - $response = $gapicClient->updateNetwork($network); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateNetwork', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getNetwork(); - $this->assertProtobufEquals($network, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateNetworkExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateNetworkTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $network = new Network(); - $response = $gapicClient->updateNetwork($network); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateNfsShareTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateNfsShareTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $nfsShareId = 'nfsShareId931294079'; - $volume = 'volume-810883302'; - $expectedResponse = new NfsShare(); - $expectedResponse->setName($name); - $expectedResponse->setNfsShareId($nfsShareId); - $expectedResponse->setVolume($volume); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateNfsShareTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $nfsShare = new NfsShare(); - $response = $gapicClient->updateNfsShare($nfsShare); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateNfsShare', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getNfsShare(); - $this->assertProtobufEquals($nfsShare, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNfsShareTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateNfsShareExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateNfsShareTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $nfsShare = new NfsShare(); - $response = $gapicClient->updateNfsShare($nfsShare); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNfsShareTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateVolumeTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateVolumeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $requestedSizeGib = 525454387; - $currentSizeGib = 72696456; - $emergencySizeGib = 1936971120; - $autoGrownSizeGib = 1245638678; - $remainingSpaceGib = 1423108606; - $snapshotEnabled = true; - $pod = 'pod111173'; - $expectedResponse = new Volume(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setRequestedSizeGib($requestedSizeGib); - $expectedResponse->setCurrentSizeGib($currentSizeGib); - $expectedResponse->setEmergencySizeGib($emergencySizeGib); - $expectedResponse->setAutoGrownSizeGib($autoGrownSizeGib); - $expectedResponse->setRemainingSpaceGib($remainingSpaceGib); - $expectedResponse->setSnapshotEnabled($snapshotEnabled); - $expectedResponse->setPod($pod); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateVolumeTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $volume = new Volume(); - $response = $gapicClient->updateVolume($volume); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.baremetalsolution.v2.BareMetalSolution/UpdateVolume', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getVolume(); - $this->assertProtobufEquals($volume, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateVolumeTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateVolumeExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateVolumeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $volume = new Volume(); - $response = $gapicClient->updateVolume($volume); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateVolumeTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Batch.php b/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Batch.php deleted file mode 100644 index 08b6865323ca..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Batch.php +++ /dev/null @@ -1,91 +0,0 @@ -internalAddGeneratedFile( - ' -Ò -!google/cloud/batch/v1/batch.protogoogle.cloud.batch.v1google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.protogoogle/cloud/batch/v1/job.proto google/cloud/batch/v1/task.proto#google/longrunning/operations.protogoogle/protobuf/empty.protogoogle/protobuf/timestamp.proto"› -CreateJobRequest0 -parent ( B àAúAbatch.googleapis.com/Job -job_id ( , -job ( 2.google.cloud.batch.v1.JobBàA - -request_id ( BàA"? - GetJobRequest. -name ( B àAúA -batch.googleapis.com/Job"N -DeleteJobRequest -name (  -reason ( BàA - -request_id ( BàA"X -ListJobsRequest -parent (  -filter (  - page_size ( - -page_token ( "j -ListJobsResponse( -jobs ( 2.google.cloud.batch.v1.Job -next_page_token (  - unreachable ( " -ListTasksRequest6 -parent ( B&àAúA -batch.googleapis.com/TaskGroup -filter (  - page_size ( - -page_token ( "m -ListTasksResponse* -tasks ( 2.google.cloud.batch.v1.Task -next_page_token (  - unreachable ( "A -GetTaskRequest/ -name ( B!àAúA -batch.googleapis.com/Task"€ -OperationMetadata4 - create_time ( 2.google.protobuf.TimestampBàA1 -end_time ( 2.google.protobuf.TimestampBàA -target ( BàA -verb ( BàA -status_message ( BàA# -requested_cancellation (BàA - api_version ( BàA2¶ - BatchService› - CreateJob\'.google.cloud.batch.v1.CreateJobRequest.google.cloud.batch.v1.Job"I‚Óä“/"(/v1/{parent=projects/*/locations/*}/jobs:jobÚAparent,job,job_idƒ -GetJob$.google.cloud.batch.v1.GetJobRequest.google.cloud.batch.v1.Job"7‚Óä“*(/v1/{name=projects/*/locations/*/jobs/*}ÚAnameÏ - DeleteJob\'.google.cloud.batch.v1.DeleteJobRequest.google.longrunning.Operation"z‚Óä“**(/v1/{name=projects/*/locations/*/jobs/*}ÚAnameÊA@ -google.protobuf.Empty\'google.cloud.batch.v1.OperationMetadata– -ListJobs&.google.cloud.batch.v1.ListJobsRequest\'.google.cloud.batch.v1.ListJobsResponse"9‚Óä“*(/v1/{parent=projects/*/locations/*}/jobsÚAparent› -GetTask%.google.cloud.batch.v1.GetTaskRequest.google.cloud.batch.v1.Task"L‚Óä“?=/v1/{name=projects/*/locations/*/jobs/*/taskGroups/*/tasks/*}ÚAname® - ListTasks\'.google.cloud.batch.v1.ListTasksRequest(.google.cloud.batch.v1.ListTasksResponse"N‚Óä“?=/v1/{parent=projects/*/locations/*/jobs/*/taskGroups/*}/tasksÚAparentHÊAbatch.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformB« -com.google.cloud.batch.v1B -BatchProtoPZ/cloud.google.com/go/batch/apiv1/batchpb;batchpb¢GCBªGoogle.Cloud.Batch.V1ÊGoogle\\Cloud\\Batch\\V1êGoogle::Cloud::Batch::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Job.php b/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Job.php deleted file mode 100644 index 562591488590b5ab3a61109d35752f9ca8eae616..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5386 zcmbtYTXWmS6%I*V$U}*u;7e#`#zvU5Rwgl6F^QYdaU9-6(UwR?q}*wTGbjkIC|DqX zU;#O*M>FkfpZXj6)=ppgANtgX&a}Uvj~V}lKJ@G^08z9UQ>`9E5;))4-E+Qk+pnHD z#}0fTH;F}D%_AducqV(tM0Q-;vvu2)hyKwKab?|}IEG1FMV9Lwx!vi@je4v9K0>MO zyE-Y$W7{5^q^O&=KPnD2Pd_f6ZWmwJLxt-Cu(S!Gj;0g2*{$vqPaA2THfVC#pvGW> zDuWH4Z$ARiO^s6dsXc^OAmg9o4^2atsi%4P@u5Lg!!kTWGmYQit{=-snn?-b-jqG^ zE!{J0OJ;zMrIW3XWTBJEe(2bE%ExlJkuEzp9(vHSJmOlKIj9q=yN2W0ZWl$%!k_%n%KS28ivc}UU&ed4%z6W0$ zfwL;3QRJH)?)1|iv;h(O-1j$@Yq72@P}ncU@%CVu*Bjh7n5UKscPcim4uXqgl~*; z@#!Z?$3=1&-dQezj}uZE(rh>C*tLC!=9c8dR=OlBSDsX1PHr+mravxKVN)|rTjw5B z9UH^&EVqhk)1|@vIVvgv3uvxeriA)vD>qW+^658Yi(LGvx6?{7{hCat<;n#DP(D66^KQH_x1~7G= zDx^mks)ogh!grD>J$S1f6wI$72?w$!|1vH3z1($f;}!MpWFuit7{`mIh|J#6>7 zjaqA`)u?CRLHK%YuX9*e_d3mHtKH1Tq$DhLEB)PUyztvqNJTV3Vl6XbiAc(neuR&L zR|@+e(wDH#U_MpJDX~0?n`EI>m~%{lZ7@-(aa9cdYz{Em=tVSA5fMdLbA3w<6G(2E z^X*QkC*pRPbMyaHmCqX)T0;!>Gd+NxbCzy;_D*0s51?q^&|0@O? zQJM-4wFfJ@?K7XmxKF;CqwxyU3Jpq)!-bivkTL?Jg-$NMRpDhbvk;wDIX^@bEJXAA z)R_WjUxGZDj_P#j8q^WzV~Z4C!7}?rq+77r>sR`XnGgb4`S!4Jh~X5&G?MDob{qA> zJ^UG$(y)4P*lx49O7M4wwOXT5$9GE-!geYxCbul*;AXwC*WmHlYOCFYPV=DA>t$C8 z|B1r}ntwWvF)m_nNByDd*^Z$H8SDwHV%?|OSmdyDNtti_X?4oJK;{1ygVo?W2JKQr z^GxaE1vT|CG9;Fy$xHQxJya=A7p%-Ko-Uq1hQT@i1)kO8%>2U1NG-f25>DY6Eb)!p zglzwp-C1v;6Q6dfs&Hg&x6*EM$K3|0U+F!Yc^)tPum;)Lh?RCB8K!q`{B-Hz91G1t zv6_k66;!m|bj*l4|IMPR!q5?_I&Pm#9Fy_%YuKQ~JvDTqYB~?_pcVMZ9MwG`T@k`k zE$Td0cv|>$4(!dtO|>CAuxb(SrR|;sozLfsYH16YI9C2+$jsR6j_9sll93vEK_swL z{ySJ=$xhmUWn;o3fo00n?mLnMNor{hJ+?ib{@Js&DUPQQvPy9vG#R+zHtIu>ml!&EUBnaAzGIKRWcCbx+wkXS|Ig|fu403bBc^6h3 zF+#8r<{G)?vPR_3d$7q}j%|(V1=&LMjQr(~@L>}+#2zAC{uhu9BDEDp2n(Vx==r#X zaR*qZ!e@dmcj2~WtK@reS)dw@s*OfC9|qjZ6Ij2L0;E1jfrg7<3|p2j7PWVvGTQ4k zr-8z+Ve`#KtpIniRzGj`u(8G>ukLrSjL)$zSc8Dgb+6m$V{fnl>Fz2qVoVtm+s9uJ}-(WCgxG}0_NN{@4Fl1!HE*A)})UO9rX6Y`N;dWtRhH3zXG z+a^cjWX8A5$Ncj`5i&Ey5VIzkXoeYdSs9$Jb=x7L!%bEH6oWfB5nk2js@g02Ku48^!}TZfw$N$1@sP-XtQjq|qhd zGWi32>3`@WzoO6m3w`5}$G&%_XLlvXF>wRULo6NbclKPqbI$I=$L^jB*W?DZsiy~Y zAooXdut#Ora{|Y3EV&=<>`+fOoS|!4)Kg@+wkfwZyK=qO>|RBv?}VN~Re9HOb}d>o zEGHZk`+8vP6%W>nf$r}sTp56^52^3!29+D_$_pCk13l1t4UX$o8Ln4hxZd{q0|3L) zeP8Y(9^QhCe{R^fOhfhqJ;0yqrmvZ{8JN0d{(^RI$UC~_Qv`mzb|C>!6<-a%@SPxsGo4nsz`vTeo^O>KmTv29DRprK-A1gK@x^WbJ0OEmLRi z$ZNtzRsG1w4LR^aI=Q z98&d@;p33hLSzX>@_#_PCT2g-hwjN(o`u_w%qZsN!C)NXCrG@taZp%@ZovBsa4O@- zs^Fx;IjL|?DhKQN!pT%U;6V{&&0mhzaOxr%ii61W==+uF??LRISWwu6nwnzZUT}X?)SS&wdFY+BMGGORyJUl*zCWUSmX4opW<54f@kY=xxtiriY zx7@93FI$~#bU|)mTYjiZbO+r`c%XrzHEd^|IAspHi6j`6uP( zbNnzz7D4K~tXAvw8os6rf6qZ?E3|FBZ&C6HIpf%YZeoAtQOK5V&M-5^DAgG7^bENV z^P+b}>HqpPaEEs~M5?gR*FDd~edjp~X6ACdaYd|0a2|-cYdaoAE@2Kuv^iBXjPrfn z*x&V>&>nDxahYzt)KoR9lh{#^p3alBZCnnQh;YN018R3a;o!Pz&|?SY_)#Oz0Vypii*vx>@Z85TtQ z@X^i`)*}iWmz9vuZIH-ixX`y8gB6#UDw<7$*N(TJlhDQt+b8tdxWP&Vl<=Kh9D%rI zkjpYj{tnEG^pGW(bM;_P)H%i*-vd<4lPo z(uNfQ$Gq4BJgVV9VIwYEy8Bs*us#Jk{}n6?-D452#&}HlXlH6IU3d)hkqH-ol&jt5 zW^1ZVF9B@TyIVhL-E!v{c4}gx~X z04|B6hZwxNYx)XSN|A5yBetYh)Cm0I+vw@Ah;4!&vQQR39u{9YeSF9Nhx|<4!0zdy zAYk*FwNh8eBhg{uw-jV2SU_qZ9q69PYF&hBHjgJ@%65$5JSIQDicbwZv1&)k#PGZ~ zBNmg&IvhHsvI*y@ZD2da+sA}fcC5*kZheB*XD>Rq$qU`hW7`_Pu!f3+*Nz$ zh4jH|6(^M2e-Qoto=i2Wm3PV22ER-x{J5`F*kwxDUjH+e_o7=?bj`wh)`w(HKvb1u pRF#8Nb$h)(&!^>`8{?DrEpd67xa+WLFpU%LIeewKk{rSzz`wA-aP|NI diff --git a/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Volume.php b/owl-bot-staging/Batch/v1/proto/src/GPBMetadata/Google/Cloud/Batch/V1/Volume.php deleted file mode 100644 index fa8ca8061c1c73d2e747bfcc335cfc3d120737af..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1026 zcmaiz-Hy^g6vqXW$Pm52kkq|8;wB45OIYuUXk>A5FI-66aABH|VK~4fZKs(|N!0K% zUT%C6U&O?xa6Yfp5*D99Z4go^lwcx)MZQ|0 z1SaB?M<{)O(FD#X7w~R$cJV}8Gm%S%0jz~sN7!YN$d}y(RczDU_PSdUq^r_mm!LeDyYt6rvNd_8)2mMD}7jlvOT zO!8C-In~l2Sfkosnu)YKMOl-Mub}OE41ya?4nWBquU7|BskXjC9R1ukugn_{2z?q`t&0XE-+~cvWqw>2QOPSmcSCr&MjcyC$lo4_r*7 zW^b8y4=U~2@II+J;#$v0Mb~dU)B%)Rl(yGe;}NM#jD_CrZy#}3clTj|n3g^{zV})Ych{nzou*s^Z|^c)^o#RbSr;B&mYWW8-$L$N$o*OG z$5lKm=r8cs{QoL@&JqOH69m>21hd|vYJaDfNBiABcSv0$@UQe)r2}n8c7*%}XQevv diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy.php deleted file mode 100644 index 20b0362ee475..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy.php +++ /dev/null @@ -1,262 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy - */ -class AllocationPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Location where compute resources should be allocated for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.LocationPolicy location = 1; - */ - protected $location = null; - /** - * Describe instances that can be created by this AllocationPolicy. - * Only instances[0] is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.InstancePolicyOrTemplate instances = 8; - */ - private $instances; - /** - * Service account that VMs will run as. - * - * Generated from protobuf field .google.cloud.batch.v1.ServiceAccount service_account = 9; - */ - protected $service_account = null; - /** - * Labels applied to all VM instances and other resources - * created by AllocationPolicy. - * Labels could be user provided or system generated. - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 6; - */ - private $labels; - /** - * The network policy. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.NetworkPolicy network = 7; - */ - protected $network = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Batch\V1\AllocationPolicy\LocationPolicy $location - * Location where compute resources should be allocated for the Job. - * @type array<\Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicyOrTemplate>|\Google\Protobuf\Internal\RepeatedField $instances - * Describe instances that can be created by this AllocationPolicy. - * Only instances[0] is supported now. - * @type \Google\Cloud\Batch\V1\ServiceAccount $service_account - * Service account that VMs will run as. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels applied to all VM instances and other resources - * created by AllocationPolicy. - * Labels could be user provided or system generated. - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * @type \Google\Cloud\Batch\V1\AllocationPolicy\NetworkPolicy $network - * The network policy. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Location where compute resources should be allocated for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.LocationPolicy location = 1; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\LocationPolicy|null - */ - public function getLocation() - { - return $this->location; - } - - public function hasLocation() - { - return isset($this->location); - } - - public function clearLocation() - { - unset($this->location); - } - - /** - * Location where compute resources should be allocated for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.LocationPolicy location = 1; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\LocationPolicy $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\LocationPolicy::class); - $this->location = $var; - - return $this; - } - - /** - * Describe instances that can be created by this AllocationPolicy. - * Only instances[0] is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.InstancePolicyOrTemplate instances = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInstances() - { - return $this->instances; - } - - /** - * Describe instances that can be created by this AllocationPolicy. - * Only instances[0] is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.InstancePolicyOrTemplate instances = 8; - * @param array<\Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicyOrTemplate>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInstances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicyOrTemplate::class); - $this->instances = $arr; - - return $this; - } - - /** - * Service account that VMs will run as. - * - * Generated from protobuf field .google.cloud.batch.v1.ServiceAccount service_account = 9; - * @return \Google\Cloud\Batch\V1\ServiceAccount|null - */ - public function getServiceAccount() - { - return $this->service_account; - } - - public function hasServiceAccount() - { - return isset($this->service_account); - } - - public function clearServiceAccount() - { - unset($this->service_account); - } - - /** - * Service account that VMs will run as. - * - * Generated from protobuf field .google.cloud.batch.v1.ServiceAccount service_account = 9; - * @param \Google\Cloud\Batch\V1\ServiceAccount $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\ServiceAccount::class); - $this->service_account = $var; - - return $this; - } - - /** - * Labels applied to all VM instances and other resources - * created by AllocationPolicy. - * Labels could be user provided or system generated. - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 6; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels applied to all VM instances and other resources - * created by AllocationPolicy. - * Labels could be user provided or system generated. - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 6; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * The network policy. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.NetworkPolicy network = 7; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\NetworkPolicy|null - */ - public function getNetwork() - { - return $this->network; - } - - public function hasNetwork() - { - return isset($this->network); - } - - public function clearNetwork() - { - unset($this->network); - } - - /** - * The network policy. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.NetworkPolicy network = 7; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\NetworkPolicy $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\NetworkPolicy::class); - $this->network = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Accelerator.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Accelerator.php deleted file mode 100644 index ce0e80128600..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Accelerator.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.Accelerator - */ -class Accelerator extends \Google\Protobuf\Internal\Message -{ - /** - * The accelerator type. For example, "nvidia-tesla-t4". - * See `gcloud compute accelerator-types list`. - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * The number of accelerators of this type. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - /** - * Deprecated: please use instances[0].install_gpu_drivers instead. - * - * Generated from protobuf field bool install_gpu_drivers = 3 [deprecated = true]; - * @deprecated - */ - protected $install_gpu_drivers = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * The accelerator type. For example, "nvidia-tesla-t4". - * See `gcloud compute accelerator-types list`. - * @type int|string $count - * The number of accelerators of this type. - * @type bool $install_gpu_drivers - * Deprecated: please use instances[0].install_gpu_drivers instead. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The accelerator type. For example, "nvidia-tesla-t4". - * See `gcloud compute accelerator-types list`. - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The accelerator type. For example, "nvidia-tesla-t4". - * See `gcloud compute accelerator-types list`. - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * The number of accelerators of this type. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * The number of accelerators of this type. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - - /** - * Deprecated: please use instances[0].install_gpu_drivers instead. - * - * Generated from protobuf field bool install_gpu_drivers = 3 [deprecated = true]; - * @return bool - * @deprecated - */ - public function getInstallGpuDrivers() - { - @trigger_error('install_gpu_drivers is deprecated.', E_USER_DEPRECATED); - return $this->install_gpu_drivers; - } - - /** - * Deprecated: please use instances[0].install_gpu_drivers instead. - * - * Generated from protobuf field bool install_gpu_drivers = 3 [deprecated = true]; - * @param bool $var - * @return $this - * @deprecated - */ - public function setInstallGpuDrivers($var) - { - @trigger_error('install_gpu_drivers is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkBool($var); - $this->install_gpu_drivers = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Accelerator::class, \Google\Cloud\Batch\V1\AllocationPolicy_Accelerator::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/AttachedDisk.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/AttachedDisk.php deleted file mode 100644 index d57b97912d09..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/AttachedDisk.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.AttachedDisk - */ -class AttachedDisk extends \Google\Protobuf\Internal\Message -{ - /** - * Device name that the guest operating system will see. - * It is used by Runnable.volumes field to mount disks. So please specify - * the device_name if you want Batch to help mount the disk, and it should - * match the device_name field in volumes. - * - * Generated from protobuf field string device_name = 3; - */ - protected $device_name = ''; - protected $attached; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Batch\V1\AllocationPolicy\Disk $new_disk - * @type string $existing_disk - * Name of an existing PD. - * @type string $device_name - * Device name that the guest operating system will see. - * It is used by Runnable.volumes field to mount disks. So please specify - * the device_name if you want Batch to help mount the disk, and it should - * match the device_name field in volumes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk new_disk = 1; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\Disk|null - */ - public function getNewDisk() - { - return $this->readOneof(1); - } - - public function hasNewDisk() - { - return $this->hasOneof(1); - } - - /** - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk new_disk = 1; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\Disk $var - * @return $this - */ - public function setNewDisk($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\Disk::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Name of an existing PD. - * - * Generated from protobuf field string existing_disk = 2; - * @return string - */ - public function getExistingDisk() - { - return $this->readOneof(2); - } - - public function hasExistingDisk() - { - return $this->hasOneof(2); - } - - /** - * Name of an existing PD. - * - * Generated from protobuf field string existing_disk = 2; - * @param string $var - * @return $this - */ - public function setExistingDisk($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Device name that the guest operating system will see. - * It is used by Runnable.volumes field to mount disks. So please specify - * the device_name if you want Batch to help mount the disk, and it should - * match the device_name field in volumes. - * - * Generated from protobuf field string device_name = 3; - * @return string - */ - public function getDeviceName() - { - return $this->device_name; - } - - /** - * Device name that the guest operating system will see. - * It is used by Runnable.volumes field to mount disks. So please specify - * the device_name if you want Batch to help mount the disk, and it should - * match the device_name field in volumes. - * - * Generated from protobuf field string device_name = 3; - * @param string $var - * @return $this - */ - public function setDeviceName($var) - { - GPBUtil::checkString($var, True); - $this->device_name = $var; - - return $this; - } - - /** - * @return string - */ - public function getAttached() - { - return $this->whichOneof("attached"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttachedDisk::class, \Google\Cloud\Batch\V1\AllocationPolicy_AttachedDisk::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Disk.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Disk.php deleted file mode 100644 index 72f07c40c715..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/Disk.php +++ /dev/null @@ -1,298 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.Disk - */ -class Disk extends \Google\Protobuf\Internal\Message -{ - /** - * Disk type as shown in `gcloud compute disk-types list`. - * For example, local SSD uses type "local-ssd". - * Persistent disks and boot disks use "pd-balanced", "pd-extreme", "pd-ssd" - * or "pd-standard". - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * Disk size in GB. - * For persistent disk, this field is ignored if `data_source` is `image` or - * `snapshot`. - * For local SSD, size_gb should be a multiple of 375GB, - * otherwise, the final size will be the next greater multiple of 375 GB. - * For boot disk, Batch will calculate the boot disk size based on source - * image and task requirements if you do not speicify the size. - * If both this field and the boot_disk_mib field in task spec's - * compute_resource are defined, Batch will only honor this field. - * - * Generated from protobuf field int64 size_gb = 2; - */ - protected $size_gb = 0; - /** - * Local SSDs are available through both "SCSI" and "NVMe" interfaces. - * If not indicated, "NVMe" will be the default one for local ssds. - * We only support "SCSI" for persistent disks now. - * - * Generated from protobuf field string disk_interface = 6; - */ - protected $disk_interface = ''; - protected $data_source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $image - * Name of a public or custom image used as the data source. - * For example, the following are all valid URLs: - * (1) Specify the image by its family name: - * projects/{project}/global/images/family/{image_family} - * (2) Specify the image version: - * projects/{project}/global/images/{image_version} - * You can also use Batch customized image in short names. - * The following image values are supported for a boot disk: - * "batch-debian": use Batch Debian images. - * "batch-centos": use Batch CentOS images. - * "batch-cos": use Batch Container-Optimized images. - * @type string $snapshot - * Name of a snapshot used as the data source. - * @type string $type - * Disk type as shown in `gcloud compute disk-types list`. - * For example, local SSD uses type "local-ssd". - * Persistent disks and boot disks use "pd-balanced", "pd-extreme", "pd-ssd" - * or "pd-standard". - * @type int|string $size_gb - * Disk size in GB. - * For persistent disk, this field is ignored if `data_source` is `image` or - * `snapshot`. - * For local SSD, size_gb should be a multiple of 375GB, - * otherwise, the final size will be the next greater multiple of 375 GB. - * For boot disk, Batch will calculate the boot disk size based on source - * image and task requirements if you do not speicify the size. - * If both this field and the boot_disk_mib field in task spec's - * compute_resource are defined, Batch will only honor this field. - * @type string $disk_interface - * Local SSDs are available through both "SCSI" and "NVMe" interfaces. - * If not indicated, "NVMe" will be the default one for local ssds. - * We only support "SCSI" for persistent disks now. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Name of a public or custom image used as the data source. - * For example, the following are all valid URLs: - * (1) Specify the image by its family name: - * projects/{project}/global/images/family/{image_family} - * (2) Specify the image version: - * projects/{project}/global/images/{image_version} - * You can also use Batch customized image in short names. - * The following image values are supported for a boot disk: - * "batch-debian": use Batch Debian images. - * "batch-centos": use Batch CentOS images. - * "batch-cos": use Batch Container-Optimized images. - * - * Generated from protobuf field string image = 4; - * @return string - */ - public function getImage() - { - return $this->readOneof(4); - } - - public function hasImage() - { - return $this->hasOneof(4); - } - - /** - * Name of a public or custom image used as the data source. - * For example, the following are all valid URLs: - * (1) Specify the image by its family name: - * projects/{project}/global/images/family/{image_family} - * (2) Specify the image version: - * projects/{project}/global/images/{image_version} - * You can also use Batch customized image in short names. - * The following image values are supported for a boot disk: - * "batch-debian": use Batch Debian images. - * "batch-centos": use Batch CentOS images. - * "batch-cos": use Batch Container-Optimized images. - * - * Generated from protobuf field string image = 4; - * @param string $var - * @return $this - */ - public function setImage($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Name of a snapshot used as the data source. - * - * Generated from protobuf field string snapshot = 5; - * @return string - */ - public function getSnapshot() - { - return $this->readOneof(5); - } - - public function hasSnapshot() - { - return $this->hasOneof(5); - } - - /** - * Name of a snapshot used as the data source. - * - * Generated from protobuf field string snapshot = 5; - * @param string $var - * @return $this - */ - public function setSnapshot($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Disk type as shown in `gcloud compute disk-types list`. - * For example, local SSD uses type "local-ssd". - * Persistent disks and boot disks use "pd-balanced", "pd-extreme", "pd-ssd" - * or "pd-standard". - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Disk type as shown in `gcloud compute disk-types list`. - * For example, local SSD uses type "local-ssd". - * Persistent disks and boot disks use "pd-balanced", "pd-extreme", "pd-ssd" - * or "pd-standard". - * - * Generated from protobuf field string type = 1; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Disk size in GB. - * For persistent disk, this field is ignored if `data_source` is `image` or - * `snapshot`. - * For local SSD, size_gb should be a multiple of 375GB, - * otherwise, the final size will be the next greater multiple of 375 GB. - * For boot disk, Batch will calculate the boot disk size based on source - * image and task requirements if you do not speicify the size. - * If both this field and the boot_disk_mib field in task spec's - * compute_resource are defined, Batch will only honor this field. - * - * Generated from protobuf field int64 size_gb = 2; - * @return int|string - */ - public function getSizeGb() - { - return $this->size_gb; - } - - /** - * Disk size in GB. - * For persistent disk, this field is ignored if `data_source` is `image` or - * `snapshot`. - * For local SSD, size_gb should be a multiple of 375GB, - * otherwise, the final size will be the next greater multiple of 375 GB. - * For boot disk, Batch will calculate the boot disk size based on source - * image and task requirements if you do not speicify the size. - * If both this field and the boot_disk_mib field in task spec's - * compute_resource are defined, Batch will only honor this field. - * - * Generated from protobuf field int64 size_gb = 2; - * @param int|string $var - * @return $this - */ - public function setSizeGb($var) - { - GPBUtil::checkInt64($var); - $this->size_gb = $var; - - return $this; - } - - /** - * Local SSDs are available through both "SCSI" and "NVMe" interfaces. - * If not indicated, "NVMe" will be the default one for local ssds. - * We only support "SCSI" for persistent disks now. - * - * Generated from protobuf field string disk_interface = 6; - * @return string - */ - public function getDiskInterface() - { - return $this->disk_interface; - } - - /** - * Local SSDs are available through both "SCSI" and "NVMe" interfaces. - * If not indicated, "NVMe" will be the default one for local ssds. - * We only support "SCSI" for persistent disks now. - * - * Generated from protobuf field string disk_interface = 6; - * @param string $var - * @return $this - */ - public function setDiskInterface($var) - { - GPBUtil::checkString($var, True); - $this->disk_interface = $var; - - return $this; - } - - /** - * @return string - */ - public function getDataSource() - { - return $this->whichOneof("data_source"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Disk::class, \Google\Cloud\Batch\V1\AllocationPolicy_Disk::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicy.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicy.php deleted file mode 100644 index 5be6f1b9036a..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicy.php +++ /dev/null @@ -1,271 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.InstancePolicy - */ -class InstancePolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 2; - */ - protected $machine_type = ''; - /** - * The minimum CPU platform. - * See - * `https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform`. - * Not yet implemented. - * - * Generated from protobuf field string min_cpu_platform = 3; - */ - protected $min_cpu_platform = ''; - /** - * The provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 4; - */ - protected $provisioning_model = 0; - /** - * The accelerators attached to each VM instance. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.Accelerator accelerators = 5; - */ - private $accelerators; - /** - * Book disk to be created and attached to each VM by this InstancePolicy. - * Boot disk will be deleted when the VM is deleted. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 8; - */ - protected $boot_disk = null; - /** - * Non-boot disks to be attached for each VM created by this InstancePolicy. - * New disks will be deleted when the VM is deleted. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.AttachedDisk disks = 6; - */ - private $disks; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $machine_type - * The Compute Engine machine type. - * @type string $min_cpu_platform - * The minimum CPU platform. - * See - * `https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform`. - * Not yet implemented. - * @type int $provisioning_model - * The provisioning model. - * @type array<\Google\Cloud\Batch\V1\AllocationPolicy\Accelerator>|\Google\Protobuf\Internal\RepeatedField $accelerators - * The accelerators attached to each VM instance. - * @type \Google\Cloud\Batch\V1\AllocationPolicy\Disk $boot_disk - * Book disk to be created and attached to each VM by this InstancePolicy. - * Boot disk will be deleted when the VM is deleted. - * @type array<\Google\Cloud\Batch\V1\AllocationPolicy\AttachedDisk>|\Google\Protobuf\Internal\RepeatedField $disks - * Non-boot disks to be attached for each VM created by this InstancePolicy. - * New disks will be deleted when the VM is deleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 2; - * @return string - */ - public function getMachineType() - { - return $this->machine_type; - } - - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 2; - * @param string $var - * @return $this - */ - public function setMachineType($var) - { - GPBUtil::checkString($var, True); - $this->machine_type = $var; - - return $this; - } - - /** - * The minimum CPU platform. - * See - * `https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform`. - * Not yet implemented. - * - * Generated from protobuf field string min_cpu_platform = 3; - * @return string - */ - public function getMinCpuPlatform() - { - return $this->min_cpu_platform; - } - - /** - * The minimum CPU platform. - * See - * `https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform`. - * Not yet implemented. - * - * Generated from protobuf field string min_cpu_platform = 3; - * @param string $var - * @return $this - */ - public function setMinCpuPlatform($var) - { - GPBUtil::checkString($var, True); - $this->min_cpu_platform = $var; - - return $this; - } - - /** - * The provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 4; - * @return int - */ - public function getProvisioningModel() - { - return $this->provisioning_model; - } - - /** - * The provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 4; - * @param int $var - * @return $this - */ - public function setProvisioningModel($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\AllocationPolicy\ProvisioningModel::class); - $this->provisioning_model = $var; - - return $this; - } - - /** - * The accelerators attached to each VM instance. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.Accelerator accelerators = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAccelerators() - { - return $this->accelerators; - } - - /** - * The accelerators attached to each VM instance. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.Accelerator accelerators = 5; - * @param array<\Google\Cloud\Batch\V1\AllocationPolicy\Accelerator>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAccelerators($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\AllocationPolicy\Accelerator::class); - $this->accelerators = $arr; - - return $this; - } - - /** - * Book disk to be created and attached to each VM by this InstancePolicy. - * Boot disk will be deleted when the VM is deleted. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 8; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\Disk|null - */ - public function getBootDisk() - { - return $this->boot_disk; - } - - public function hasBootDisk() - { - return isset($this->boot_disk); - } - - public function clearBootDisk() - { - unset($this->boot_disk); - } - - /** - * Book disk to be created and attached to each VM by this InstancePolicy. - * Boot disk will be deleted when the VM is deleted. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 8; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\Disk $var - * @return $this - */ - public function setBootDisk($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\Disk::class); - $this->boot_disk = $var; - - return $this; - } - - /** - * Non-boot disks to be attached for each VM created by this InstancePolicy. - * New disks will be deleted when the VM is deleted. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.AttachedDisk disks = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDisks() - { - return $this->disks; - } - - /** - * Non-boot disks to be attached for each VM created by this InstancePolicy. - * New disks will be deleted when the VM is deleted. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.AttachedDisk disks = 6; - * @param array<\Google\Cloud\Batch\V1\AllocationPolicy\AttachedDisk>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDisks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\AllocationPolicy\AttachedDisk::class); - $this->disks = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InstancePolicy::class, \Google\Cloud\Batch\V1\AllocationPolicy_InstancePolicy::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicyOrTemplate.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicyOrTemplate.php deleted file mode 100644 index daf830b8540d..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/InstancePolicyOrTemplate.php +++ /dev/null @@ -1,163 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.InstancePolicyOrTemplate - */ -class InstancePolicyOrTemplate extends \Google\Protobuf\Internal\Message -{ - /** - * Set this field true if users want Batch to help fetch drivers from a - * third party location and install them for GPUs specified in - * policy.accelerators or instance_template on their behalf. Default is - * false. - * - * Generated from protobuf field bool install_gpu_drivers = 3; - */ - protected $install_gpu_drivers = false; - protected $policy_template; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicy $policy - * InstancePolicy. - * @type string $instance_template - * Name of an instance template used to create VMs. - * Named the field as 'instance_template' instead of 'template' to avoid - * c++ keyword conflict. - * @type bool $install_gpu_drivers - * Set this field true if users want Batch to help fetch drivers from a - * third party location and install them for GPUs specified in - * policy.accelerators or instance_template on their behalf. Default is - * false. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * InstancePolicy. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicy|null - */ - public function getPolicy() - { - return $this->readOneof(1); - } - - public function hasPolicy() - { - return $this->hasOneof(1); - } - - /** - * InstancePolicy. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicy $var - * @return $this - */ - public function setPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\InstancePolicy::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Name of an instance template used to create VMs. - * Named the field as 'instance_template' instead of 'template' to avoid - * c++ keyword conflict. - * - * Generated from protobuf field string instance_template = 2; - * @return string - */ - public function getInstanceTemplate() - { - return $this->readOneof(2); - } - - public function hasInstanceTemplate() - { - return $this->hasOneof(2); - } - - /** - * Name of an instance template used to create VMs. - * Named the field as 'instance_template' instead of 'template' to avoid - * c++ keyword conflict. - * - * Generated from protobuf field string instance_template = 2; - * @param string $var - * @return $this - */ - public function setInstanceTemplate($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Set this field true if users want Batch to help fetch drivers from a - * third party location and install them for GPUs specified in - * policy.accelerators or instance_template on their behalf. Default is - * false. - * - * Generated from protobuf field bool install_gpu_drivers = 3; - * @return bool - */ - public function getInstallGpuDrivers() - { - return $this->install_gpu_drivers; - } - - /** - * Set this field true if users want Batch to help fetch drivers from a - * third party location and install them for GPUs specified in - * policy.accelerators or instance_template on their behalf. Default is - * false. - * - * Generated from protobuf field bool install_gpu_drivers = 3; - * @param bool $var - * @return $this - */ - public function setInstallGpuDrivers($var) - { - GPBUtil::checkBool($var); - $this->install_gpu_drivers = $var; - - return $this; - } - - /** - * @return string - */ - public function getPolicyTemplate() - { - return $this->whichOneof("policy_template"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InstancePolicyOrTemplate::class, \Google\Cloud\Batch\V1\AllocationPolicy_InstancePolicyOrTemplate::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/LocationPolicy.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/LocationPolicy.php deleted file mode 100644 index 4a0711636785..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/LocationPolicy.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.LocationPolicy - */ -class LocationPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * A list of allowed location names represented by internal URLs. - * Each location can be a region or a zone. - * Only one region or multiple zones in one region is supported now. - * For example, - * ["regions/us-central1"] allow VMs in any zones in region us-central1. - * ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs - * in zones us-central1-a and us-central1-c. - * All locations end up in different regions would cause errors. - * For example, - * ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b", - * "zones/us-west1-a"] contains 2 regions "us-central1" and - * "us-west1". An error is expected in this case. - * - * Generated from protobuf field repeated string allowed_locations = 1; - */ - private $allowed_locations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $allowed_locations - * A list of allowed location names represented by internal URLs. - * Each location can be a region or a zone. - * Only one region or multiple zones in one region is supported now. - * For example, - * ["regions/us-central1"] allow VMs in any zones in region us-central1. - * ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs - * in zones us-central1-a and us-central1-c. - * All locations end up in different regions would cause errors. - * For example, - * ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b", - * "zones/us-west1-a"] contains 2 regions "us-central1" and - * "us-west1". An error is expected in this case. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * A list of allowed location names represented by internal URLs. - * Each location can be a region or a zone. - * Only one region or multiple zones in one region is supported now. - * For example, - * ["regions/us-central1"] allow VMs in any zones in region us-central1. - * ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs - * in zones us-central1-a and us-central1-c. - * All locations end up in different regions would cause errors. - * For example, - * ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b", - * "zones/us-west1-a"] contains 2 regions "us-central1" and - * "us-west1". An error is expected in this case. - * - * Generated from protobuf field repeated string allowed_locations = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowedLocations() - { - return $this->allowed_locations; - } - - /** - * A list of allowed location names represented by internal URLs. - * Each location can be a region or a zone. - * Only one region or multiple zones in one region is supported now. - * For example, - * ["regions/us-central1"] allow VMs in any zones in region us-central1. - * ["zones/us-central1-a", "zones/us-central1-c"] only allow VMs - * in zones us-central1-a and us-central1-c. - * All locations end up in different regions would cause errors. - * For example, - * ["regions/us-central1", "zones/us-central1-a", "zones/us-central1-b", - * "zones/us-west1-a"] contains 2 regions "us-central1" and - * "us-west1". An error is expected in this case. - * - * Generated from protobuf field repeated string allowed_locations = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowedLocations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->allowed_locations = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LocationPolicy::class, \Google\Cloud\Batch\V1\AllocationPolicy_LocationPolicy::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkInterface.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkInterface.php deleted file mode 100644 index bf6597d781cb..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkInterface.php +++ /dev/null @@ -1,202 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.NetworkInterface - */ -class NetworkInterface extends \Google\Protobuf\Internal\Message -{ - /** - * The URL of an existing network resource. - * You can specify the network as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/global/networks/{network} - * projects/{project}/global/networks/{network} - * global/networks/{network} - * - * Generated from protobuf field string network = 1; - */ - protected $network = ''; - /** - * The URL of an existing subnetwork resource in the network. - * You can specify the subnetwork as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/subnetworks/{subnetwork} - * projects/{project}/regions/{region}/subnetworks/{subnetwork} - * regions/{region}/subnetworks/{subnetwork} - * - * Generated from protobuf field string subnetwork = 2; - */ - protected $subnetwork = ''; - /** - * Default is false (with an external IP address). Required if - * no external public IP address is attached to the VM. If no external - * public IP address, additional configuration is required to allow the VM - * to access Google Services. See - * https://cloud.google.com/vpc/docs/configure-private-google-access and - * https://cloud.google.com/nat/docs/gce-example#create-nat for more - * information. - * - * Generated from protobuf field bool no_external_ip_address = 3; - */ - protected $no_external_ip_address = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network - * The URL of an existing network resource. - * You can specify the network as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/global/networks/{network} - * projects/{project}/global/networks/{network} - * global/networks/{network} - * @type string $subnetwork - * The URL of an existing subnetwork resource in the network. - * You can specify the subnetwork as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/subnetworks/{subnetwork} - * projects/{project}/regions/{region}/subnetworks/{subnetwork} - * regions/{region}/subnetworks/{subnetwork} - * @type bool $no_external_ip_address - * Default is false (with an external IP address). Required if - * no external public IP address is attached to the VM. If no external - * public IP address, additional configuration is required to allow the VM - * to access Google Services. See - * https://cloud.google.com/vpc/docs/configure-private-google-access and - * https://cloud.google.com/nat/docs/gce-example#create-nat for more - * information. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The URL of an existing network resource. - * You can specify the network as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/global/networks/{network} - * projects/{project}/global/networks/{network} - * global/networks/{network} - * - * Generated from protobuf field string network = 1; - * @return string - */ - public function getNetwork() - { - return $this->network; - } - - /** - * The URL of an existing network resource. - * You can specify the network as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/global/networks/{network} - * projects/{project}/global/networks/{network} - * global/networks/{network} - * - * Generated from protobuf field string network = 1; - * @param string $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkString($var, True); - $this->network = $var; - - return $this; - } - - /** - * The URL of an existing subnetwork resource in the network. - * You can specify the subnetwork as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/subnetworks/{subnetwork} - * projects/{project}/regions/{region}/subnetworks/{subnetwork} - * regions/{region}/subnetworks/{subnetwork} - * - * Generated from protobuf field string subnetwork = 2; - * @return string - */ - public function getSubnetwork() - { - return $this->subnetwork; - } - - /** - * The URL of an existing subnetwork resource in the network. - * You can specify the subnetwork as a full or partial URL. - * For example, the following are all valid URLs: - * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/subnetworks/{subnetwork} - * projects/{project}/regions/{region}/subnetworks/{subnetwork} - * regions/{region}/subnetworks/{subnetwork} - * - * Generated from protobuf field string subnetwork = 2; - * @param string $var - * @return $this - */ - public function setSubnetwork($var) - { - GPBUtil::checkString($var, True); - $this->subnetwork = $var; - - return $this; - } - - /** - * Default is false (with an external IP address). Required if - * no external public IP address is attached to the VM. If no external - * public IP address, additional configuration is required to allow the VM - * to access Google Services. See - * https://cloud.google.com/vpc/docs/configure-private-google-access and - * https://cloud.google.com/nat/docs/gce-example#create-nat for more - * information. - * - * Generated from protobuf field bool no_external_ip_address = 3; - * @return bool - */ - public function getNoExternalIpAddress() - { - return $this->no_external_ip_address; - } - - /** - * Default is false (with an external IP address). Required if - * no external public IP address is attached to the VM. If no external - * public IP address, additional configuration is required to allow the VM - * to access Google Services. See - * https://cloud.google.com/vpc/docs/configure-private-google-access and - * https://cloud.google.com/nat/docs/gce-example#create-nat for more - * information. - * - * Generated from protobuf field bool no_external_ip_address = 3; - * @param bool $var - * @return $this - */ - public function setNoExternalIpAddress($var) - { - GPBUtil::checkBool($var); - $this->no_external_ip_address = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NetworkInterface::class, \Google\Cloud\Batch\V1\AllocationPolicy_NetworkInterface::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkPolicy.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkPolicy.php deleted file mode 100644 index f402f3e8e3d2..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/NetworkPolicy.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.NetworkPolicy - */ -class NetworkPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Network configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.NetworkInterface network_interfaces = 1; - */ - private $network_interfaces; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Batch\V1\AllocationPolicy\NetworkInterface>|\Google\Protobuf\Internal\RepeatedField $network_interfaces - * Network configurations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Network configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.NetworkInterface network_interfaces = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNetworkInterfaces() - { - return $this->network_interfaces; - } - - /** - * Network configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.AllocationPolicy.NetworkInterface network_interfaces = 1; - * @param array<\Google\Cloud\Batch\V1\AllocationPolicy\NetworkInterface>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNetworkInterfaces($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\AllocationPolicy\NetworkInterface::class); - $this->network_interfaces = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NetworkPolicy::class, \Google\Cloud\Batch\V1\AllocationPolicy_NetworkPolicy::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/ProvisioningModel.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/ProvisioningModel.php deleted file mode 100644 index 62a6191c61cb..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy/ProvisioningModel.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.batch.v1.AllocationPolicy.ProvisioningModel - */ -class ProvisioningModel -{ - /** - * Unspecified. - * - * Generated from protobuf enum PROVISIONING_MODEL_UNSPECIFIED = 0; - */ - const PROVISIONING_MODEL_UNSPECIFIED = 0; - /** - * Standard VM. - * - * Generated from protobuf enum STANDARD = 1; - */ - const STANDARD = 1; - /** - * SPOT VM. - * - * Generated from protobuf enum SPOT = 2; - */ - const SPOT = 2; - /** - * Preemptible VM (PVM). - * Above SPOT VM is the preferable model for preemptible VM instances: the - * old preemptible VM model (indicated by this field) is the older model, - * and has been migrated to use the SPOT model as the underlying technology. - * This old model will still be supported. - * - * Generated from protobuf enum PREEMPTIBLE = 3; - */ - const PREEMPTIBLE = 3; - - private static $valueToName = [ - self::PROVISIONING_MODEL_UNSPECIFIED => 'PROVISIONING_MODEL_UNSPECIFIED', - self::STANDARD => 'STANDARD', - self::SPOT => 'SPOT', - self::PREEMPTIBLE => 'PREEMPTIBLE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ProvisioningModel::class, \Google\Cloud\Batch\V1\AllocationPolicy_ProvisioningModel::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_Accelerator.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_Accelerator.php deleted file mode 100644 index 1e85fe74a884..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/AllocationPolicy_Accelerator.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.batch.v1.BatchService/CreateJob', - $argument, - ['\Google\Cloud\Batch\V1\Job', 'decode'], - $metadata, $options); - } - - /** - * Get a Job specified by its resource name. - * @param \Google\Cloud\Batch\V1\GetJobRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetJob(\Google\Cloud\Batch\V1\GetJobRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.batch.v1.BatchService/GetJob', - $argument, - ['\Google\Cloud\Batch\V1\Job', 'decode'], - $metadata, $options); - } - - /** - * Delete a Job. - * @param \Google\Cloud\Batch\V1\DeleteJobRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteJob(\Google\Cloud\Batch\V1\DeleteJobRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.batch.v1.BatchService/DeleteJob', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * List all Jobs for a project within a region. - * @param \Google\Cloud\Batch\V1\ListJobsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListJobs(\Google\Cloud\Batch\V1\ListJobsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.batch.v1.BatchService/ListJobs', - $argument, - ['\Google\Cloud\Batch\V1\ListJobsResponse', 'decode'], - $metadata, $options); - } - - /** - * Return a single Task. - * @param \Google\Cloud\Batch\V1\GetTaskRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetTask(\Google\Cloud\Batch\V1\GetTaskRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.batch.v1.BatchService/GetTask', - $argument, - ['\Google\Cloud\Batch\V1\Task', 'decode'], - $metadata, $options); - } - - /** - * List Tasks associated with a job. - * @param \Google\Cloud\Batch\V1\ListTasksRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListTasks(\Google\Cloud\Batch\V1\ListTasksRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.batch.v1.BatchService/ListTasks', - $argument, - ['\Google\Cloud\Batch\V1\ListTasksResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ComputeResource.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ComputeResource.php deleted file mode 100644 index 16384c01afdd..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ComputeResource.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.batch.v1.ComputeResource - */ -class ComputeResource extends \Google\Protobuf\Internal\Message -{ - /** - * The milliCPU count. - * - * Generated from protobuf field int64 cpu_milli = 1; - */ - protected $cpu_milli = 0; - /** - * Memory in MiB. - * - * Generated from protobuf field int64 memory_mib = 2; - */ - protected $memory_mib = 0; - /** - * Extra boot disk size in MiB for each task. - * - * Generated from protobuf field int64 boot_disk_mib = 4; - */ - protected $boot_disk_mib = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $cpu_milli - * The milliCPU count. - * @type int|string $memory_mib - * Memory in MiB. - * @type int|string $boot_disk_mib - * Extra boot disk size in MiB for each task. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * The milliCPU count. - * - * Generated from protobuf field int64 cpu_milli = 1; - * @return int|string - */ - public function getCpuMilli() - { - return $this->cpu_milli; - } - - /** - * The milliCPU count. - * - * Generated from protobuf field int64 cpu_milli = 1; - * @param int|string $var - * @return $this - */ - public function setCpuMilli($var) - { - GPBUtil::checkInt64($var); - $this->cpu_milli = $var; - - return $this; - } - - /** - * Memory in MiB. - * - * Generated from protobuf field int64 memory_mib = 2; - * @return int|string - */ - public function getMemoryMib() - { - return $this->memory_mib; - } - - /** - * Memory in MiB. - * - * Generated from protobuf field int64 memory_mib = 2; - * @param int|string $var - * @return $this - */ - public function setMemoryMib($var) - { - GPBUtil::checkInt64($var); - $this->memory_mib = $var; - - return $this; - } - - /** - * Extra boot disk size in MiB for each task. - * - * Generated from protobuf field int64 boot_disk_mib = 4; - * @return int|string - */ - public function getBootDiskMib() - { - return $this->boot_disk_mib; - } - - /** - * Extra boot disk size in MiB for each task. - * - * Generated from protobuf field int64 boot_disk_mib = 4; - * @param int|string $var - * @return $this - */ - public function setBootDiskMib($var) - { - GPBUtil::checkInt64($var); - $this->boot_disk_mib = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/CreateJobRequest.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/CreateJobRequest.php deleted file mode 100644 index fdec8fae5402..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/CreateJobRequest.php +++ /dev/null @@ -1,278 +0,0 @@ -google.cloud.batch.v1.CreateJobRequest - */ -class CreateJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * - * Generated from protobuf field string job_id = 2; - */ - protected $job_id = ''; - /** - * Required. The Job to create. - * - * Generated from protobuf field .google.cloud.batch.v1.Job job = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $job = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * Please see {@see BatchServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Batch\V1\Job $job Required. The Job to create. - * @param string $jobId ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * - * @return \Google\Cloud\Batch\V1\CreateJobRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Batch\V1\Job $job, string $jobId): self - { - return (new self()) - ->setParent($parent) - ->setJob($job) - ->setJobId($jobId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * @type string $job_id - * ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * @type \Google\Cloud\Batch\V1\Job $job - * Required. The Job to create. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * - * Generated from protobuf field string job_id = 2; - * @return string - */ - public function getJobId() - { - return $this->job_id; - } - - /** - * ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * - * Generated from protobuf field string job_id = 2; - * @param string $var - * @return $this - */ - public function setJobId($var) - { - GPBUtil::checkString($var, True); - $this->job_id = $var; - - return $this; - } - - /** - * Required. The Job to create. - * - * Generated from protobuf field .google.cloud.batch.v1.Job job = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Batch\V1\Job|null - */ - public function getJob() - { - return $this->job; - } - - public function hasJob() - { - return isset($this->job); - } - - public function clearJob() - { - unset($this->job); - } - - /** - * Required. The Job to create. - * - * Generated from protobuf field .google.cloud.batch.v1.Job job = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Batch\V1\Job $var - * @return $this - */ - public function setJob($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Job::class); - $this->job = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/DeleteJobRequest.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/DeleteJobRequest.php deleted file mode 100644 index 0acc2dfbbac6..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/DeleteJobRequest.php +++ /dev/null @@ -1,188 +0,0 @@ -google.cloud.batch.v1.DeleteJobRequest - */ -class DeleteJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Job name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Optional. Reason for this deletion. - * - * Generated from protobuf field string reason = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $reason = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Job name. - * - * @return \Google\Cloud\Batch\V1\DeleteJobRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Job name. - * @type string $reason - * Optional. Reason for this deletion. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Job name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Job name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. Reason for this deletion. - * - * Generated from protobuf field string reason = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getReason() - { - return $this->reason; - } - - /** - * Optional. Reason for this deletion. - * - * Generated from protobuf field string reason = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setReason($var) - { - GPBUtil::checkString($var, True); - $this->reason = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment.php deleted file mode 100644 index 058a8d4ccc90..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment.php +++ /dev/null @@ -1,158 +0,0 @@ -google.cloud.batch.v1.Environment - */ -class Environment extends \Google\Protobuf\Internal\Message -{ - /** - * A map of environment variable names to values. - * - * Generated from protobuf field map variables = 1; - */ - private $variables; - /** - * A map of environment variable names to Secret Manager secret names. - * The VM will access the named secrets to set the value of each environment - * variable. - * - * Generated from protobuf field map secret_variables = 2; - */ - private $secret_variables; - /** - * An encrypted JSON dictionary where the key/value pairs correspond to - * environment variable names and their values. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment.KMSEnvMap encrypted_variables = 3; - */ - protected $encrypted_variables = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $variables - * A map of environment variable names to values. - * @type array|\Google\Protobuf\Internal\MapField $secret_variables - * A map of environment variable names to Secret Manager secret names. - * The VM will access the named secrets to set the value of each environment - * variable. - * @type \Google\Cloud\Batch\V1\Environment\KMSEnvMap $encrypted_variables - * An encrypted JSON dictionary where the key/value pairs correspond to - * environment variable names and their values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * A map of environment variable names to values. - * - * Generated from protobuf field map variables = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getVariables() - { - return $this->variables; - } - - /** - * A map of environment variable names to values. - * - * Generated from protobuf field map variables = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setVariables($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->variables = $arr; - - return $this; - } - - /** - * A map of environment variable names to Secret Manager secret names. - * The VM will access the named secrets to set the value of each environment - * variable. - * - * Generated from protobuf field map secret_variables = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSecretVariables() - { - return $this->secret_variables; - } - - /** - * A map of environment variable names to Secret Manager secret names. - * The VM will access the named secrets to set the value of each environment - * variable. - * - * Generated from protobuf field map secret_variables = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSecretVariables($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->secret_variables = $arr; - - return $this; - } - - /** - * An encrypted JSON dictionary where the key/value pairs correspond to - * environment variable names and their values. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment.KMSEnvMap encrypted_variables = 3; - * @return \Google\Cloud\Batch\V1\Environment\KMSEnvMap|null - */ - public function getEncryptedVariables() - { - return $this->encrypted_variables; - } - - public function hasEncryptedVariables() - { - return isset($this->encrypted_variables); - } - - public function clearEncryptedVariables() - { - unset($this->encrypted_variables); - } - - /** - * An encrypted JSON dictionary where the key/value pairs correspond to - * environment variable names and their values. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment.KMSEnvMap encrypted_variables = 3; - * @param \Google\Cloud\Batch\V1\Environment\KMSEnvMap $var - * @return $this - */ - public function setEncryptedVariables($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Environment\KMSEnvMap::class); - $this->encrypted_variables = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment/KMSEnvMap.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment/KMSEnvMap.php deleted file mode 100644 index 91b995831e11..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment/KMSEnvMap.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.batch.v1.Environment.KMSEnvMap - */ -class KMSEnvMap extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the KMS key that will be used to decrypt the cipher text. - * - * Generated from protobuf field string key_name = 1; - */ - protected $key_name = ''; - /** - * The value of the cipherText response from the `encrypt` method. - * - * Generated from protobuf field string cipher_text = 2; - */ - protected $cipher_text = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_name - * The name of the KMS key that will be used to decrypt the cipher text. - * @type string $cipher_text - * The value of the cipherText response from the `encrypt` method. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * The name of the KMS key that will be used to decrypt the cipher text. - * - * Generated from protobuf field string key_name = 1; - * @return string - */ - public function getKeyName() - { - return $this->key_name; - } - - /** - * The name of the KMS key that will be used to decrypt the cipher text. - * - * Generated from protobuf field string key_name = 1; - * @param string $var - * @return $this - */ - public function setKeyName($var) - { - GPBUtil::checkString($var, True); - $this->key_name = $var; - - return $this; - } - - /** - * The value of the cipherText response from the `encrypt` method. - * - * Generated from protobuf field string cipher_text = 2; - * @return string - */ - public function getCipherText() - { - return $this->cipher_text; - } - - /** - * The value of the cipherText response from the `encrypt` method. - * - * Generated from protobuf field string cipher_text = 2; - * @param string $var - * @return $this - */ - public function setCipherText($var) - { - GPBUtil::checkString($var, True); - $this->cipher_text = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KMSEnvMap::class, \Google\Cloud\Batch\V1\Environment_KMSEnvMap::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment_KMSEnvMap.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment_KMSEnvMap.php deleted file mode 100644 index 75085c6ee530..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Environment_KMSEnvMap.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.GCS - */ -class GCS extends \Google\Protobuf\Internal\Message -{ - /** - * Remote path, either a bucket name or a subdirectory of a bucket, e.g.: - * bucket_name, bucket_name/subdirectory/ - * - * Generated from protobuf field string remote_path = 1; - */ - protected $remote_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $remote_path - * Remote path, either a bucket name or a subdirectory of a bucket, e.g.: - * bucket_name, bucket_name/subdirectory/ - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Volume::initOnce(); - parent::__construct($data); - } - - /** - * Remote path, either a bucket name or a subdirectory of a bucket, e.g.: - * bucket_name, bucket_name/subdirectory/ - * - * Generated from protobuf field string remote_path = 1; - * @return string - */ - public function getRemotePath() - { - return $this->remote_path; - } - - /** - * Remote path, either a bucket name or a subdirectory of a bucket, e.g.: - * bucket_name, bucket_name/subdirectory/ - * - * Generated from protobuf field string remote_path = 1; - * @param string $var - * @return $this - */ - public function setRemotePath($var) - { - GPBUtil::checkString($var, True); - $this->remote_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetJobRequest.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetJobRequest.php deleted file mode 100644 index ae27090d4139..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetJobRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.batch.v1.GetJobRequest - */ -class GetJobRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Job name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Job name. Please see - * {@see BatchServiceClient::jobName()} for help formatting this field. - * - * @return \Google\Cloud\Batch\V1\GetJobRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Job name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Required. Job name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Job name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetTaskRequest.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetTaskRequest.php deleted file mode 100644 index 6271a4460bce..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/GetTaskRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.batch.v1.GetTaskRequest - */ -class GetTaskRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Task name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Task name. Please see - * {@see BatchServiceClient::taskName()} for help formatting this field. - * - * @return \Google\Cloud\Batch\V1\GetTaskRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Task name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Required. Task name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Task name. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Job.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Job.php deleted file mode 100644 index e32bd5a11b00..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Job.php +++ /dev/null @@ -1,513 +0,0 @@ -google.cloud.batch.v1.Job - */ -class Job extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Job name. - * For example: "projects/123456/locations/us-central1/jobs/job01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. A system generated unique ID (in UUID4 format) for the Job. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Priority of the Job. - * The valid value range is [0, 100). Default value is 0. - * Higher value indicates higher priority. - * A job with higher priority value is more likely to run earlier if all other - * requirements are satisfied. - * - * Generated from protobuf field int64 priority = 3; - */ - protected $priority = 0; - /** - * Required. TaskGroups in the Job. Only one TaskGroup is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.TaskGroup task_groups = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $task_groups; - /** - * Compute resource allocation for all TaskGroups in the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy allocation_policy = 7; - */ - protected $allocation_policy = null; - /** - * Labels for the Job. Labels could be user provided or system generated. - * For example, - * "labels": { - * "department": "finance", - * "environment": "test" - * } - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 8; - */ - private $labels; - /** - * Output only. Job status. It is read only for users. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus status = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status = null; - /** - * Output only. When the Job was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last time the Job was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Log preservation policy for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy logs_policy = 13; - */ - protected $logs_policy = null; - /** - * Notification configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobNotification notifications = 14; - */ - private $notifications; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Job name. - * For example: "projects/123456/locations/us-central1/jobs/job01". - * @type string $uid - * Output only. A system generated unique ID (in UUID4 format) for the Job. - * @type int|string $priority - * Priority of the Job. - * The valid value range is [0, 100). Default value is 0. - * Higher value indicates higher priority. - * A job with higher priority value is more likely to run earlier if all other - * requirements are satisfied. - * @type array<\Google\Cloud\Batch\V1\TaskGroup>|\Google\Protobuf\Internal\RepeatedField $task_groups - * Required. TaskGroups in the Job. Only one TaskGroup is supported now. - * @type \Google\Cloud\Batch\V1\AllocationPolicy $allocation_policy - * Compute resource allocation for all TaskGroups in the Job. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels for the Job. Labels could be user provided or system generated. - * For example, - * "labels": { - * "department": "finance", - * "environment": "test" - * } - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * @type \Google\Cloud\Batch\V1\JobStatus $status - * Output only. Job status. It is read only for users. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. When the Job was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last time the Job was updated. - * @type \Google\Cloud\Batch\V1\LogsPolicy $logs_policy - * Log preservation policy for the Job. - * @type array<\Google\Cloud\Batch\V1\JobNotification>|\Google\Protobuf\Internal\RepeatedField $notifications - * Notification configurations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Job name. - * For example: "projects/123456/locations/us-central1/jobs/job01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Job name. - * For example: "projects/123456/locations/us-central1/jobs/job01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. A system generated unique ID (in UUID4 format) for the Job. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. A system generated unique ID (in UUID4 format) for the Job. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Priority of the Job. - * The valid value range is [0, 100). Default value is 0. - * Higher value indicates higher priority. - * A job with higher priority value is more likely to run earlier if all other - * requirements are satisfied. - * - * Generated from protobuf field int64 priority = 3; - * @return int|string - */ - public function getPriority() - { - return $this->priority; - } - - /** - * Priority of the Job. - * The valid value range is [0, 100). Default value is 0. - * Higher value indicates higher priority. - * A job with higher priority value is more likely to run earlier if all other - * requirements are satisfied. - * - * Generated from protobuf field int64 priority = 3; - * @param int|string $var - * @return $this - */ - public function setPriority($var) - { - GPBUtil::checkInt64($var); - $this->priority = $var; - - return $this; - } - - /** - * Required. TaskGroups in the Job. Only one TaskGroup is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.TaskGroup task_groups = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTaskGroups() - { - return $this->task_groups; - } - - /** - * Required. TaskGroups in the Job. Only one TaskGroup is supported now. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.TaskGroup task_groups = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Batch\V1\TaskGroup>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTaskGroups($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\TaskGroup::class); - $this->task_groups = $arr; - - return $this; - } - - /** - * Compute resource allocation for all TaskGroups in the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy allocation_policy = 7; - * @return \Google\Cloud\Batch\V1\AllocationPolicy|null - */ - public function getAllocationPolicy() - { - return $this->allocation_policy; - } - - public function hasAllocationPolicy() - { - return isset($this->allocation_policy); - } - - public function clearAllocationPolicy() - { - unset($this->allocation_policy); - } - - /** - * Compute resource allocation for all TaskGroups in the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy allocation_policy = 7; - * @param \Google\Cloud\Batch\V1\AllocationPolicy $var - * @return $this - */ - public function setAllocationPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy::class); - $this->allocation_policy = $var; - - return $this; - } - - /** - * Labels for the Job. Labels could be user provided or system generated. - * For example, - * "labels": { - * "department": "finance", - * "environment": "test" - * } - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 8; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels for the Job. Labels could be user provided or system generated. - * For example, - * "labels": { - * "department": "finance", - * "environment": "test" - * } - * You can assign up to 64 labels. [Google Compute Engine label - * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions) - * apply. - * Label names that start with "goog-" or "google-" are reserved. - * - * Generated from protobuf field map labels = 8; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Output only. Job status. It is read only for users. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus status = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Batch\V1\JobStatus|null - */ - public function getStatus() - { - return $this->status; - } - - public function hasStatus() - { - return isset($this->status); - } - - public function clearStatus() - { - unset($this->status); - } - - /** - * Output only. Job status. It is read only for users. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus status = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Batch\V1\JobStatus $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\JobStatus::class); - $this->status = $var; - - return $this; - } - - /** - * Output only. When the Job was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. When the Job was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The last time the Job was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The last time the Job was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Log preservation policy for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy logs_policy = 13; - * @return \Google\Cloud\Batch\V1\LogsPolicy|null - */ - public function getLogsPolicy() - { - return $this->logs_policy; - } - - public function hasLogsPolicy() - { - return isset($this->logs_policy); - } - - public function clearLogsPolicy() - { - unset($this->logs_policy); - } - - /** - * Log preservation policy for the Job. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy logs_policy = 13; - * @param \Google\Cloud\Batch\V1\LogsPolicy $var - * @return $this - */ - public function setLogsPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\LogsPolicy::class); - $this->logs_policy = $var; - - return $this; - } - - /** - * Notification configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobNotification notifications = 14; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotifications() - { - return $this->notifications; - } - - /** - * Notification configurations. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobNotification notifications = 14; - * @param array<\Google\Cloud\Batch\V1\JobNotification>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotifications($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\JobNotification::class); - $this->notifications = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification.php deleted file mode 100644 index 3c1fc88bdeab..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification.php +++ /dev/null @@ -1,131 +0,0 @@ -google.cloud.batch.v1.JobNotification - */ -class JobNotification extends \Google\Protobuf\Internal\Message -{ - /** - * The Pub/Sub topic where notifications like the job state changes - * will be published. This topic exist in the same project as the job - * and billings will be charged to this project. - * If not specified, no Pub/Sub messages will be sent. - * Topic format: `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string pubsub_topic = 1; - */ - protected $pubsub_topic = ''; - /** - * The attribute requirements of messages to be sent to this Pub/Sub topic. - * Without this field, no message will be sent. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Message message = 2; - */ - protected $message = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $pubsub_topic - * The Pub/Sub topic where notifications like the job state changes - * will be published. This topic exist in the same project as the job - * and billings will be charged to this project. - * If not specified, no Pub/Sub messages will be sent. - * Topic format: `projects/{project}/topics/{topic}`. - * @type \Google\Cloud\Batch\V1\JobNotification\Message $message - * The attribute requirements of messages to be sent to this Pub/Sub topic. - * Without this field, no message will be sent. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The Pub/Sub topic where notifications like the job state changes - * will be published. This topic exist in the same project as the job - * and billings will be charged to this project. - * If not specified, no Pub/Sub messages will be sent. - * Topic format: `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string pubsub_topic = 1; - * @return string - */ - public function getPubsubTopic() - { - return $this->pubsub_topic; - } - - /** - * The Pub/Sub topic where notifications like the job state changes - * will be published. This topic exist in the same project as the job - * and billings will be charged to this project. - * If not specified, no Pub/Sub messages will be sent. - * Topic format: `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string pubsub_topic = 1; - * @param string $var - * @return $this - */ - public function setPubsubTopic($var) - { - GPBUtil::checkString($var, True); - $this->pubsub_topic = $var; - - return $this; - } - - /** - * The attribute requirements of messages to be sent to this Pub/Sub topic. - * Without this field, no message will be sent. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Message message = 2; - * @return \Google\Cloud\Batch\V1\JobNotification\Message|null - */ - public function getMessage() - { - return $this->message; - } - - public function hasMessage() - { - return isset($this->message); - } - - public function clearMessage() - { - unset($this->message); - } - - /** - * The attribute requirements of messages to be sent to this Pub/Sub topic. - * Without this field, no message will be sent. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Message message = 2; - * @param \Google\Cloud\Batch\V1\JobNotification\Message $var - * @return $this - */ - public function setMessage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\JobNotification\Message::class); - $this->message = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Message.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Message.php deleted file mode 100644 index af67b119fb29..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Message.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.batch.v1.JobNotification.Message - */ -class Message extends \Google\Protobuf\Internal\Message -{ - /** - * The message type. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Type type = 1; - */ - protected $type = 0; - /** - * The new job state. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State new_job_state = 2; - */ - protected $new_job_state = 0; - /** - * The new task state. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State new_task_state = 3; - */ - protected $new_task_state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The message type. - * @type int $new_job_state - * The new job state. - * @type int $new_task_state - * The new task state. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The message type. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Type type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The message type. - * - * Generated from protobuf field .google.cloud.batch.v1.JobNotification.Type type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\JobNotification\Type::class); - $this->type = $var; - - return $this; - } - - /** - * The new job state. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State new_job_state = 2; - * @return int - */ - public function getNewJobState() - { - return $this->new_job_state; - } - - /** - * The new job state. - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State new_job_state = 2; - * @param int $var - * @return $this - */ - public function setNewJobState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\JobStatus\State::class); - $this->new_job_state = $var; - - return $this; - } - - /** - * The new task state. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State new_task_state = 3; - * @return int - */ - public function getNewTaskState() - { - return $this->new_task_state; - } - - /** - * The new task state. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State new_task_state = 3; - * @param int $var - * @return $this - */ - public function setNewTaskState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\TaskStatus\State::class); - $this->new_task_state = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Message::class, \Google\Cloud\Batch\V1\JobNotification_Message::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Type.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Type.php deleted file mode 100644 index 28ccf868f4c0..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification/Type.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.batch.v1.JobNotification.Type - */ -class Type -{ - /** - * Unspecified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Notify users that the job state has changed. - * - * Generated from protobuf enum JOB_STATE_CHANGED = 1; - */ - const JOB_STATE_CHANGED = 1; - /** - * Notify users that the task state has changed. - * - * Generated from protobuf enum TASK_STATE_CHANGED = 2; - */ - const TASK_STATE_CHANGED = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::JOB_STATE_CHANGED => 'JOB_STATE_CHANGED', - self::TASK_STATE_CHANGED => 'TASK_STATE_CHANGED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\Batch\V1\JobNotification_Type::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification_Message.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification_Message.php deleted file mode 100644 index 0e84573a896a..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobNotification_Message.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.JobStatus - */ -class JobStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Job state - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State state = 1; - */ - protected $state = 0; - /** - * Job status events - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - */ - private $status_events; - /** - * Aggregated task status for each TaskGroup in the Job. - * The map key is TaskGroup ID. - * - * Generated from protobuf field map task_groups = 4; - */ - private $task_groups; - /** - * The duration of time that the Job spent in status RUNNING. - * - * Generated from protobuf field .google.protobuf.Duration run_duration = 5; - */ - protected $run_duration = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * Job state - * @type array<\Google\Cloud\Batch\V1\StatusEvent>|\Google\Protobuf\Internal\RepeatedField $status_events - * Job status events - * @type array|\Google\Protobuf\Internal\MapField $task_groups - * Aggregated task status for each TaskGroup in the Job. - * The map key is TaskGroup ID. - * @type \Google\Protobuf\Duration $run_duration - * The duration of time that the Job spent in status RUNNING. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Job state - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State state = 1; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Job state - * - * Generated from protobuf field .google.cloud.batch.v1.JobStatus.State state = 1; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\JobStatus\State::class); - $this->state = $var; - - return $this; - } - - /** - * Job status events - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getStatusEvents() - { - return $this->status_events; - } - - /** - * Job status events - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - * @param array<\Google\Cloud\Batch\V1\StatusEvent>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setStatusEvents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\StatusEvent::class); - $this->status_events = $arr; - - return $this; - } - - /** - * Aggregated task status for each TaskGroup in the Job. - * The map key is TaskGroup ID. - * - * Generated from protobuf field map task_groups = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getTaskGroups() - { - return $this->task_groups; - } - - /** - * Aggregated task status for each TaskGroup in the Job. - * The map key is TaskGroup ID. - * - * Generated from protobuf field map task_groups = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setTaskGroups($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\JobStatus\TaskGroupStatus::class); - $this->task_groups = $arr; - - return $this; - } - - /** - * The duration of time that the Job spent in status RUNNING. - * - * Generated from protobuf field .google.protobuf.Duration run_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getRunDuration() - { - return $this->run_duration; - } - - public function hasRunDuration() - { - return isset($this->run_duration); - } - - public function clearRunDuration() - { - unset($this->run_duration); - } - - /** - * The duration of time that the Job spent in status RUNNING. - * - * Generated from protobuf field .google.protobuf.Duration run_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setRunDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->run_duration = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/InstanceStatus.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/InstanceStatus.php deleted file mode 100644 index 4073a44ab3bc..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/InstanceStatus.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.batch.v1.JobStatus.InstanceStatus - */ -class InstanceStatus extends \Google\Protobuf\Internal\Message -{ - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 1; - */ - protected $machine_type = ''; - /** - * The VM instance provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 2; - */ - protected $provisioning_model = 0; - /** - * The max number of tasks can be assigned to this instance type. - * - * Generated from protobuf field int64 task_pack = 3; - */ - protected $task_pack = 0; - /** - * The VM boot disk. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 4; - */ - protected $boot_disk = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $machine_type - * The Compute Engine machine type. - * @type int $provisioning_model - * The VM instance provisioning model. - * @type int|string $task_pack - * The max number of tasks can be assigned to this instance type. - * @type \Google\Cloud\Batch\V1\AllocationPolicy\Disk $boot_disk - * The VM boot disk. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 1; - * @return string - */ - public function getMachineType() - { - return $this->machine_type; - } - - /** - * The Compute Engine machine type. - * - * Generated from protobuf field string machine_type = 1; - * @param string $var - * @return $this - */ - public function setMachineType($var) - { - GPBUtil::checkString($var, True); - $this->machine_type = $var; - - return $this; - } - - /** - * The VM instance provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 2; - * @return int - */ - public function getProvisioningModel() - { - return $this->provisioning_model; - } - - /** - * The VM instance provisioning model. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.ProvisioningModel provisioning_model = 2; - * @param int $var - * @return $this - */ - public function setProvisioningModel($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\AllocationPolicy\ProvisioningModel::class); - $this->provisioning_model = $var; - - return $this; - } - - /** - * The max number of tasks can be assigned to this instance type. - * - * Generated from protobuf field int64 task_pack = 3; - * @return int|string - */ - public function getTaskPack() - { - return $this->task_pack; - } - - /** - * The max number of tasks can be assigned to this instance type. - * - * Generated from protobuf field int64 task_pack = 3; - * @param int|string $var - * @return $this - */ - public function setTaskPack($var) - { - GPBUtil::checkInt64($var); - $this->task_pack = $var; - - return $this; - } - - /** - * The VM boot disk. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 4; - * @return \Google\Cloud\Batch\V1\AllocationPolicy\Disk|null - */ - public function getBootDisk() - { - return $this->boot_disk; - } - - public function hasBootDisk() - { - return isset($this->boot_disk); - } - - public function clearBootDisk() - { - unset($this->boot_disk); - } - - /** - * The VM boot disk. - * - * Generated from protobuf field .google.cloud.batch.v1.AllocationPolicy.Disk boot_disk = 4; - * @param \Google\Cloud\Batch\V1\AllocationPolicy\Disk $var - * @return $this - */ - public function setBootDisk($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\AllocationPolicy\Disk::class); - $this->boot_disk = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InstanceStatus::class, \Google\Cloud\Batch\V1\JobStatus_InstanceStatus::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/State.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/State.php deleted file mode 100644 index 51436382ff04..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/State.php +++ /dev/null @@ -1,94 +0,0 @@ -google.cloud.batch.v1.JobStatus.State - */ -class State -{ - /** - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Job is admitted (validated and persisted) and waiting for resources. - * - * Generated from protobuf enum QUEUED = 1; - */ - const QUEUED = 1; - /** - * Job is scheduled to run as soon as resource allocation is ready. - * The resource allocation may happen at a later time but with a high - * chance to succeed. - * - * Generated from protobuf enum SCHEDULED = 2; - */ - const SCHEDULED = 2; - /** - * Resource allocation has been successful. At least one Task in the Job is - * RUNNING. - * - * Generated from protobuf enum RUNNING = 3; - */ - const RUNNING = 3; - /** - * All Tasks in the Job have finished successfully. - * - * Generated from protobuf enum SUCCEEDED = 4; - */ - const SUCCEEDED = 4; - /** - * At least one Task in the Job has failed. - * - * Generated from protobuf enum FAILED = 5; - */ - const FAILED = 5; - /** - * The Job will be deleted, but has not been deleted yet. Typically this is - * because resources used by the Job are still being cleaned up. - * - * Generated from protobuf enum DELETION_IN_PROGRESS = 6; - */ - const DELETION_IN_PROGRESS = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::QUEUED => 'QUEUED', - self::SCHEDULED => 'SCHEDULED', - self::RUNNING => 'RUNNING', - self::SUCCEEDED => 'SUCCEEDED', - self::FAILED => 'FAILED', - self::DELETION_IN_PROGRESS => 'DELETION_IN_PROGRESS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Batch\V1\JobStatus_State::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/TaskGroupStatus.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/TaskGroupStatus.php deleted file mode 100644 index 54e870456e18..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus/TaskGroupStatus.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.batch.v1.JobStatus.TaskGroupStatus - */ -class TaskGroupStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Count of task in each state in the TaskGroup. - * The map key is task state name. - * - * Generated from protobuf field map counts = 1; - */ - private $counts; - /** - * Status of instances allocated for the TaskGroup. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobStatus.InstanceStatus instances = 2; - */ - private $instances; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $counts - * Count of task in each state in the TaskGroup. - * The map key is task state name. - * @type array<\Google\Cloud\Batch\V1\JobStatus\InstanceStatus>|\Google\Protobuf\Internal\RepeatedField $instances - * Status of instances allocated for the TaskGroup. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Count of task in each state in the TaskGroup. - * The map key is task state name. - * - * Generated from protobuf field map counts = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getCounts() - { - return $this->counts; - } - - /** - * Count of task in each state in the TaskGroup. - * The map key is task state name. - * - * Generated from protobuf field map counts = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setCounts($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::INT64); - $this->counts = $arr; - - return $this; - } - - /** - * Status of instances allocated for the TaskGroup. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobStatus.InstanceStatus instances = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInstances() - { - return $this->instances; - } - - /** - * Status of instances allocated for the TaskGroup. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.JobStatus.InstanceStatus instances = 2; - * @param array<\Google\Cloud\Batch\V1\JobStatus\InstanceStatus>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInstances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\JobStatus\InstanceStatus::class); - $this->instances = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TaskGroupStatus::class, \Google\Cloud\Batch\V1\JobStatus_TaskGroupStatus::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_InstanceStatus.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_InstanceStatus.php deleted file mode 100644 index 28ee6c70c337..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/JobStatus_InstanceStatus.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.LifecyclePolicy - */ -class LifecyclePolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Action to execute when ActionCondition is true. - * When RETRY_TASK is specified, we will retry failed tasks - * if we notice any exit code match and fail tasks if no match is found. - * Likewise, when FAIL_TASK is specified, we will fail tasks - * if we notice any exit code match and retry tasks if no match is found. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.Action action = 1; - */ - protected $action = 0; - /** - * Conditions that decide why a task failure is dealt with a specific action. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.ActionCondition action_condition = 2; - */ - protected $action_condition = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $action - * Action to execute when ActionCondition is true. - * When RETRY_TASK is specified, we will retry failed tasks - * if we notice any exit code match and fail tasks if no match is found. - * Likewise, when FAIL_TASK is specified, we will fail tasks - * if we notice any exit code match and retry tasks if no match is found. - * @type \Google\Cloud\Batch\V1\LifecyclePolicy\ActionCondition $action_condition - * Conditions that decide why a task failure is dealt with a specific action. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Action to execute when ActionCondition is true. - * When RETRY_TASK is specified, we will retry failed tasks - * if we notice any exit code match and fail tasks if no match is found. - * Likewise, when FAIL_TASK is specified, we will fail tasks - * if we notice any exit code match and retry tasks if no match is found. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.Action action = 1; - * @return int - */ - public function getAction() - { - return $this->action; - } - - /** - * Action to execute when ActionCondition is true. - * When RETRY_TASK is specified, we will retry failed tasks - * if we notice any exit code match and fail tasks if no match is found. - * Likewise, when FAIL_TASK is specified, we will fail tasks - * if we notice any exit code match and retry tasks if no match is found. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.Action action = 1; - * @param int $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\LifecyclePolicy\Action::class); - $this->action = $var; - - return $this; - } - - /** - * Conditions that decide why a task failure is dealt with a specific action. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.ActionCondition action_condition = 2; - * @return \Google\Cloud\Batch\V1\LifecyclePolicy\ActionCondition|null - */ - public function getActionCondition() - { - return $this->action_condition; - } - - public function hasActionCondition() - { - return isset($this->action_condition); - } - - public function clearActionCondition() - { - unset($this->action_condition); - } - - /** - * Conditions that decide why a task failure is dealt with a specific action. - * - * Generated from protobuf field .google.cloud.batch.v1.LifecyclePolicy.ActionCondition action_condition = 2; - * @param \Google\Cloud\Batch\V1\LifecyclePolicy\ActionCondition $var - * @return $this - */ - public function setActionCondition($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\LifecyclePolicy\ActionCondition::class); - $this->action_condition = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/Action.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/Action.php deleted file mode 100644 index 08419071bb67..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/Action.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.batch.v1.LifecyclePolicy.Action - */ -class Action -{ - /** - * Action unspecified. - * - * Generated from protobuf enum ACTION_UNSPECIFIED = 0; - */ - const ACTION_UNSPECIFIED = 0; - /** - * Action that tasks in the group will be scheduled to re-execute. - * - * Generated from protobuf enum RETRY_TASK = 1; - */ - const RETRY_TASK = 1; - /** - * Action that tasks in the group will be stopped immediately. - * - * Generated from protobuf enum FAIL_TASK = 2; - */ - const FAIL_TASK = 2; - - private static $valueToName = [ - self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', - self::RETRY_TASK => 'RETRY_TASK', - self::FAIL_TASK => 'FAIL_TASK', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Action::class, \Google\Cloud\Batch\V1\LifecyclePolicy_Action::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/ActionCondition.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/ActionCondition.php deleted file mode 100644 index acffa97a9300..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy/ActionCondition.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.batch.v1.LifecyclePolicy.ActionCondition - */ -class ActionCondition extends \Google\Protobuf\Internal\Message -{ - /** - * Exit codes of a task execution. - * If there are more than 1 exit codes, - * when task executes with any of the exit code in the list, - * the condition is met and the action will be executed. - * - * Generated from protobuf field repeated int32 exit_codes = 1; - */ - private $exit_codes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $exit_codes - * Exit codes of a task execution. - * If there are more than 1 exit codes, - * when task executes with any of the exit code in the list, - * the condition is met and the action will be executed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Exit codes of a task execution. - * If there are more than 1 exit codes, - * when task executes with any of the exit code in the list, - * the condition is met and the action will be executed. - * - * Generated from protobuf field repeated int32 exit_codes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExitCodes() - { - return $this->exit_codes; - } - - /** - * Exit codes of a task execution. - * If there are more than 1 exit codes, - * when task executes with any of the exit code in the list, - * the condition is met and the action will be executed. - * - * Generated from protobuf field repeated int32 exit_codes = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExitCodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->exit_codes = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ActionCondition::class, \Google\Cloud\Batch\V1\LifecyclePolicy_ActionCondition::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy_Action.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy_Action.php deleted file mode 100644 index f63ebd057b78..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LifecyclePolicy_Action.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.ListJobsRequest - */ -class ListJobsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Parent path. - * - * Generated from protobuf field string parent = 1; - */ - protected $parent = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Parent path. - * - * @return \Google\Cloud\Batch\V1\ListJobsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Parent path. - * @type string $filter - * List filter. - * @type int $page_size - * Page size. - * @type string $page_token - * Page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Parent path. - * - * Generated from protobuf field string parent = 1; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Parent path. - * - * Generated from protobuf field string parent = 1; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListJobsResponse.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListJobsResponse.php deleted file mode 100644 index 9874dbeed530..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListJobsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.batch.v1.ListJobsResponse - */ -class ListJobsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Jobs. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Job jobs = 1; - */ - private $jobs; - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Batch\V1\Job>|\Google\Protobuf\Internal\RepeatedField $jobs - * Jobs. - * @type string $next_page_token - * Next page token. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Jobs. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Job jobs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getJobs() - { - return $this->jobs; - } - - /** - * Jobs. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Job jobs = 1; - * @param array<\Google\Cloud\Batch\V1\Job>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setJobs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\Job::class); - $this->jobs = $arr; - - return $this; - } - - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksRequest.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksRequest.php deleted file mode 100644 index bd42658dcae9..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksRequest.php +++ /dev/null @@ -1,201 +0,0 @@ -google.cloud.batch.v1.ListTasksRequest - */ -class ListTasksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Task filter, null filter matches all Tasks. - * Filter string should be of the format State=TaskStatus.State e.g. - * State=RUNNING - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Page token. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * Please see {@see BatchServiceClient::taskGroupName()} for help formatting this field. - * - * @return \Google\Cloud\Batch\V1\ListTasksRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * @type string $filter - * Task filter, null filter matches all Tasks. - * Filter string should be of the format State=TaskStatus.State e.g. - * State=RUNNING - * @type int $page_size - * Page size. - * @type string $page_token - * Page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Task filter, null filter matches all Tasks. - * Filter string should be of the format State=TaskStatus.State e.g. - * State=RUNNING - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Task filter, null filter matches all Tasks. - * Filter string should be of the format State=TaskStatus.State e.g. - * State=RUNNING - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Page size. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksResponse.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksResponse.php deleted file mode 100644 index 7209c2e30a9f..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/ListTasksResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.batch.v1.ListTasksResponse - */ -class ListTasksResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Tasks. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Task tasks = 1; - */ - private $tasks; - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Batch\V1\Task>|\Google\Protobuf\Internal\RepeatedField $tasks - * Tasks. - * @type string $next_page_token - * Next page token. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Tasks. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Task tasks = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTasks() - { - return $this->tasks; - } - - /** - * Tasks. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Task tasks = 1; - * @param array<\Google\Cloud\Batch\V1\Task>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTasks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\Task::class); - $this->tasks = $arr; - - return $this; - } - - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Next page token. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy.php deleted file mode 100644 index 0d9e659378b6..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy.php +++ /dev/null @@ -1,110 +0,0 @@ -google.cloud.batch.v1.LogsPolicy - */ -class LogsPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Where logs should be saved. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy.Destination destination = 1; - */ - protected $destination = 0; - /** - * The path to which logs are saved when the destination = PATH. This can be a - * local file path on the VM, or under the mount point of a Persistent Disk or - * Filestore, or a Cloud Storage path. - * - * Generated from protobuf field string logs_path = 2; - */ - protected $logs_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $destination - * Where logs should be saved. - * @type string $logs_path - * The path to which logs are saved when the destination = PATH. This can be a - * local file path on the VM, or under the mount point of a Persistent Disk or - * Filestore, or a Cloud Storage path. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Where logs should be saved. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy.Destination destination = 1; - * @return int - */ - public function getDestination() - { - return $this->destination; - } - - /** - * Where logs should be saved. - * - * Generated from protobuf field .google.cloud.batch.v1.LogsPolicy.Destination destination = 1; - * @param int $var - * @return $this - */ - public function setDestination($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\LogsPolicy\Destination::class); - $this->destination = $var; - - return $this; - } - - /** - * The path to which logs are saved when the destination = PATH. This can be a - * local file path on the VM, or under the mount point of a Persistent Disk or - * Filestore, or a Cloud Storage path. - * - * Generated from protobuf field string logs_path = 2; - * @return string - */ - public function getLogsPath() - { - return $this->logs_path; - } - - /** - * The path to which logs are saved when the destination = PATH. This can be a - * local file path on the VM, or under the mount point of a Persistent Disk or - * Filestore, or a Cloud Storage path. - * - * Generated from protobuf field string logs_path = 2; - * @param string $var - * @return $this - */ - public function setLogsPath($var) - { - GPBUtil::checkString($var, True); - $this->logs_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy/Destination.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy/Destination.php deleted file mode 100644 index 1f87d09d632d..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy/Destination.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.batch.v1.LogsPolicy.Destination - */ -class Destination -{ - /** - * Logs are not preserved. - * - * Generated from protobuf enum DESTINATION_UNSPECIFIED = 0; - */ - const DESTINATION_UNSPECIFIED = 0; - /** - * Logs are streamed to Cloud Logging. - * - * Generated from protobuf enum CLOUD_LOGGING = 1; - */ - const CLOUD_LOGGING = 1; - /** - * Logs are saved to a file path. - * - * Generated from protobuf enum PATH = 2; - */ - const PATH = 2; - - private static $valueToName = [ - self::DESTINATION_UNSPECIFIED => 'DESTINATION_UNSPECIFIED', - self::CLOUD_LOGGING => 'CLOUD_LOGGING', - self::PATH => 'PATH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Destination::class, \Google\Cloud\Batch\V1\LogsPolicy_Destination::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy_Destination.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy_Destination.php deleted file mode 100644 index 5540f3354925..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/LogsPolicy_Destination.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.NFS - */ -class NFS extends \Google\Protobuf\Internal\Message -{ - /** - * The IP address of the NFS. - * - * Generated from protobuf field string server = 1; - */ - protected $server = ''; - /** - * Remote source path exported from the NFS, e.g., "/share". - * - * Generated from protobuf field string remote_path = 2; - */ - protected $remote_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $server - * The IP address of the NFS. - * @type string $remote_path - * Remote source path exported from the NFS, e.g., "/share". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Volume::initOnce(); - parent::__construct($data); - } - - /** - * The IP address of the NFS. - * - * Generated from protobuf field string server = 1; - * @return string - */ - public function getServer() - { - return $this->server; - } - - /** - * The IP address of the NFS. - * - * Generated from protobuf field string server = 1; - * @param string $var - * @return $this - */ - public function setServer($var) - { - GPBUtil::checkString($var, True); - $this->server = $var; - - return $this; - } - - /** - * Remote source path exported from the NFS, e.g., "/share". - * - * Generated from protobuf field string remote_path = 2; - * @return string - */ - public function getRemotePath() - { - return $this->remote_path; - } - - /** - * Remote source path exported from the NFS, e.g., "/share". - * - * Generated from protobuf field string remote_path = 2; - * @param string $var - * @return $this - */ - public function setRemotePath($var) - { - GPBUtil::checkString($var, True); - $this->remote_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/OperationMetadata.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/OperationMetadata.php deleted file mode 100644 index 6a98d039d45c..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/OperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.batch.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Batch::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable.php deleted file mode 100644 index 14c8f5a01604..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable.php +++ /dev/null @@ -1,372 +0,0 @@ -google.cloud.batch.v1.Runnable - */ -class Runnable extends \Google\Protobuf\Internal\Message -{ - /** - * Normally, a non-zero exit status causes the Task to fail. This flag allows - * execution of other Runnables to continue instead. - * - * Generated from protobuf field bool ignore_exit_status = 3; - */ - protected $ignore_exit_status = false; - /** - * This flag allows a Runnable to continue running in the background while the - * Task executes subsequent Runnables. This is useful to provide services to - * other Runnables (or to provide debugging support tools like SSH servers). - * - * Generated from protobuf field bool background = 4; - */ - protected $background = false; - /** - * By default, after a Runnable fails, no further Runnable are executed. This - * flag indicates that this Runnable must be run even if the Task has already - * failed. This is useful for Runnables that copy output files off of the VM - * or for debugging. - * The always_run flag does not override the Task's overall max_run_duration. - * If the max_run_duration has expired then no further Runnables will execute, - * not even always_run Runnables. - * - * Generated from protobuf field bool always_run = 5; - */ - protected $always_run = false; - /** - * Environment variables for this Runnable (overrides variables set for the - * whole Task or TaskGroup). - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 7; - */ - protected $environment = null; - /** - * Timeout for this Runnable. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - */ - protected $timeout = null; - protected $executable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Batch\V1\Runnable\Container $container - * Container runnable. - * @type \Google\Cloud\Batch\V1\Runnable\Script $script - * Script runnable. - * @type \Google\Cloud\Batch\V1\Runnable\Barrier $barrier - * Barrier runnable. - * @type bool $ignore_exit_status - * Normally, a non-zero exit status causes the Task to fail. This flag allows - * execution of other Runnables to continue instead. - * @type bool $background - * This flag allows a Runnable to continue running in the background while the - * Task executes subsequent Runnables. This is useful to provide services to - * other Runnables (or to provide debugging support tools like SSH servers). - * @type bool $always_run - * By default, after a Runnable fails, no further Runnable are executed. This - * flag indicates that this Runnable must be run even if the Task has already - * failed. This is useful for Runnables that copy output files off of the VM - * or for debugging. - * The always_run flag does not override the Task's overall max_run_duration. - * If the max_run_duration has expired then no further Runnables will execute, - * not even always_run Runnables. - * @type \Google\Cloud\Batch\V1\Environment $environment - * Environment variables for this Runnable (overrides variables set for the - * whole Task or TaskGroup). - * @type \Google\Protobuf\Duration $timeout - * Timeout for this Runnable. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Container runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Container container = 1; - * @return \Google\Cloud\Batch\V1\Runnable\Container|null - */ - public function getContainer() - { - return $this->readOneof(1); - } - - public function hasContainer() - { - return $this->hasOneof(1); - } - - /** - * Container runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Container container = 1; - * @param \Google\Cloud\Batch\V1\Runnable\Container $var - * @return $this - */ - public function setContainer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Runnable\Container::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Script runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Script script = 2; - * @return \Google\Cloud\Batch\V1\Runnable\Script|null - */ - public function getScript() - { - return $this->readOneof(2); - } - - public function hasScript() - { - return $this->hasOneof(2); - } - - /** - * Script runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Script script = 2; - * @param \Google\Cloud\Batch\V1\Runnable\Script $var - * @return $this - */ - public function setScript($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Runnable\Script::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Barrier runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Barrier barrier = 6; - * @return \Google\Cloud\Batch\V1\Runnable\Barrier|null - */ - public function getBarrier() - { - return $this->readOneof(6); - } - - public function hasBarrier() - { - return $this->hasOneof(6); - } - - /** - * Barrier runnable. - * - * Generated from protobuf field .google.cloud.batch.v1.Runnable.Barrier barrier = 6; - * @param \Google\Cloud\Batch\V1\Runnable\Barrier $var - * @return $this - */ - public function setBarrier($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Runnable\Barrier::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Normally, a non-zero exit status causes the Task to fail. This flag allows - * execution of other Runnables to continue instead. - * - * Generated from protobuf field bool ignore_exit_status = 3; - * @return bool - */ - public function getIgnoreExitStatus() - { - return $this->ignore_exit_status; - } - - /** - * Normally, a non-zero exit status causes the Task to fail. This flag allows - * execution of other Runnables to continue instead. - * - * Generated from protobuf field bool ignore_exit_status = 3; - * @param bool $var - * @return $this - */ - public function setIgnoreExitStatus($var) - { - GPBUtil::checkBool($var); - $this->ignore_exit_status = $var; - - return $this; - } - - /** - * This flag allows a Runnable to continue running in the background while the - * Task executes subsequent Runnables. This is useful to provide services to - * other Runnables (or to provide debugging support tools like SSH servers). - * - * Generated from protobuf field bool background = 4; - * @return bool - */ - public function getBackground() - { - return $this->background; - } - - /** - * This flag allows a Runnable to continue running in the background while the - * Task executes subsequent Runnables. This is useful to provide services to - * other Runnables (or to provide debugging support tools like SSH servers). - * - * Generated from protobuf field bool background = 4; - * @param bool $var - * @return $this - */ - public function setBackground($var) - { - GPBUtil::checkBool($var); - $this->background = $var; - - return $this; - } - - /** - * By default, after a Runnable fails, no further Runnable are executed. This - * flag indicates that this Runnable must be run even if the Task has already - * failed. This is useful for Runnables that copy output files off of the VM - * or for debugging. - * The always_run flag does not override the Task's overall max_run_duration. - * If the max_run_duration has expired then no further Runnables will execute, - * not even always_run Runnables. - * - * Generated from protobuf field bool always_run = 5; - * @return bool - */ - public function getAlwaysRun() - { - return $this->always_run; - } - - /** - * By default, after a Runnable fails, no further Runnable are executed. This - * flag indicates that this Runnable must be run even if the Task has already - * failed. This is useful for Runnables that copy output files off of the VM - * or for debugging. - * The always_run flag does not override the Task's overall max_run_duration. - * If the max_run_duration has expired then no further Runnables will execute, - * not even always_run Runnables. - * - * Generated from protobuf field bool always_run = 5; - * @param bool $var - * @return $this - */ - public function setAlwaysRun($var) - { - GPBUtil::checkBool($var); - $this->always_run = $var; - - return $this; - } - - /** - * Environment variables for this Runnable (overrides variables set for the - * whole Task or TaskGroup). - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 7; - * @return \Google\Cloud\Batch\V1\Environment|null - */ - public function getEnvironment() - { - return $this->environment; - } - - public function hasEnvironment() - { - return isset($this->environment); - } - - public function clearEnvironment() - { - unset($this->environment); - } - - /** - * Environment variables for this Runnable (overrides variables set for the - * whole Task or TaskGroup). - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 7; - * @param \Google\Cloud\Batch\V1\Environment $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Environment::class); - $this->environment = $var; - - return $this; - } - - /** - * Timeout for this Runnable. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Timeout for this Runnable. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 8; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * @return string - */ - public function getExecutable() - { - return $this->whichOneof("executable"); - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Barrier.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Barrier.php deleted file mode 100644 index 189d5e8cb44c..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Barrier.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.batch.v1.Runnable.Barrier - */ -class Barrier extends \Google\Protobuf\Internal\Message -{ - /** - * Barriers are identified by their index in runnable list. - * Names are not required, but if present should be an identifier. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Barriers are identified by their index in runnable list. - * Names are not required, but if present should be an identifier. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Barriers are identified by their index in runnable list. - * Names are not required, but if present should be an identifier. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Barriers are identified by their index in runnable list. - * Names are not required, but if present should be an identifier. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Barrier::class, \Google\Cloud\Batch\V1\Runnable_Barrier::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Container.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Container.php deleted file mode 100644 index c3301d6c2f2d..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Container.php +++ /dev/null @@ -1,352 +0,0 @@ -google.cloud.batch.v1.Runnable.Container - */ -class Container extends \Google\Protobuf\Internal\Message -{ - /** - * The URI to pull the container image from. - * - * Generated from protobuf field string image_uri = 1; - */ - protected $image_uri = ''; - /** - * Overrides the `CMD` specified in the container. If there is an ENTRYPOINT - * (either in the container image or with the entrypoint field below) then - * commands are appended as arguments to the ENTRYPOINT. - * - * Generated from protobuf field repeated string commands = 2; - */ - private $commands; - /** - * Overrides the `ENTRYPOINT` specified in the container. - * - * Generated from protobuf field string entrypoint = 3; - */ - protected $entrypoint = ''; - /** - * Volumes to mount (bind mount) from the host machine files or directories - * into the container, formatted to match docker run's --volume option, - * e.g. /foo:/bar, or /foo:/bar:ro - * - * Generated from protobuf field repeated string volumes = 7; - */ - private $volumes; - /** - * Arbitrary additional options to include in the "docker run" command when - * running this container, e.g. "--network host". - * - * Generated from protobuf field string options = 8; - */ - protected $options = ''; - /** - * If set to true, external network access to and from container will be - * blocked. The container will use the default internal network - * 'goog-internal'. - * - * Generated from protobuf field bool block_external_network = 9; - */ - protected $block_external_network = false; - /** - * Optional username for logging in to a docker registry. If username - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * username from the Secret Manager. - * - * Generated from protobuf field string username = 10; - */ - protected $username = ''; - /** - * Optional password for logging in to a docker registry. If password - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * password from the Secret Manager; - * - * Generated from protobuf field string password = 11; - */ - protected $password = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $image_uri - * The URI to pull the container image from. - * @type array|\Google\Protobuf\Internal\RepeatedField $commands - * Overrides the `CMD` specified in the container. If there is an ENTRYPOINT - * (either in the container image or with the entrypoint field below) then - * commands are appended as arguments to the ENTRYPOINT. - * @type string $entrypoint - * Overrides the `ENTRYPOINT` specified in the container. - * @type array|\Google\Protobuf\Internal\RepeatedField $volumes - * Volumes to mount (bind mount) from the host machine files or directories - * into the container, formatted to match docker run's --volume option, - * e.g. /foo:/bar, or /foo:/bar:ro - * @type string $options - * Arbitrary additional options to include in the "docker run" command when - * running this container, e.g. "--network host". - * @type bool $block_external_network - * If set to true, external network access to and from container will be - * blocked. The container will use the default internal network - * 'goog-internal'. - * @type string $username - * Optional username for logging in to a docker registry. If username - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * username from the Secret Manager. - * @type string $password - * Optional password for logging in to a docker registry. If password - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * password from the Secret Manager; - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * The URI to pull the container image from. - * - * Generated from protobuf field string image_uri = 1; - * @return string - */ - public function getImageUri() - { - return $this->image_uri; - } - - /** - * The URI to pull the container image from. - * - * Generated from protobuf field string image_uri = 1; - * @param string $var - * @return $this - */ - public function setImageUri($var) - { - GPBUtil::checkString($var, True); - $this->image_uri = $var; - - return $this; - } - - /** - * Overrides the `CMD` specified in the container. If there is an ENTRYPOINT - * (either in the container image or with the entrypoint field below) then - * commands are appended as arguments to the ENTRYPOINT. - * - * Generated from protobuf field repeated string commands = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCommands() - { - return $this->commands; - } - - /** - * Overrides the `CMD` specified in the container. If there is an ENTRYPOINT - * (either in the container image or with the entrypoint field below) then - * commands are appended as arguments to the ENTRYPOINT. - * - * Generated from protobuf field repeated string commands = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCommands($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->commands = $arr; - - return $this; - } - - /** - * Overrides the `ENTRYPOINT` specified in the container. - * - * Generated from protobuf field string entrypoint = 3; - * @return string - */ - public function getEntrypoint() - { - return $this->entrypoint; - } - - /** - * Overrides the `ENTRYPOINT` specified in the container. - * - * Generated from protobuf field string entrypoint = 3; - * @param string $var - * @return $this - */ - public function setEntrypoint($var) - { - GPBUtil::checkString($var, True); - $this->entrypoint = $var; - - return $this; - } - - /** - * Volumes to mount (bind mount) from the host machine files or directories - * into the container, formatted to match docker run's --volume option, - * e.g. /foo:/bar, or /foo:/bar:ro - * - * Generated from protobuf field repeated string volumes = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVolumes() - { - return $this->volumes; - } - - /** - * Volumes to mount (bind mount) from the host machine files or directories - * into the container, formatted to match docker run's --volume option, - * e.g. /foo:/bar, or /foo:/bar:ro - * - * Generated from protobuf field repeated string volumes = 7; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVolumes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->volumes = $arr; - - return $this; - } - - /** - * Arbitrary additional options to include in the "docker run" command when - * running this container, e.g. "--network host". - * - * Generated from protobuf field string options = 8; - * @return string - */ - public function getOptions() - { - return $this->options; - } - - /** - * Arbitrary additional options to include in the "docker run" command when - * running this container, e.g. "--network host". - * - * Generated from protobuf field string options = 8; - * @param string $var - * @return $this - */ - public function setOptions($var) - { - GPBUtil::checkString($var, True); - $this->options = $var; - - return $this; - } - - /** - * If set to true, external network access to and from container will be - * blocked. The container will use the default internal network - * 'goog-internal'. - * - * Generated from protobuf field bool block_external_network = 9; - * @return bool - */ - public function getBlockExternalNetwork() - { - return $this->block_external_network; - } - - /** - * If set to true, external network access to and from container will be - * blocked. The container will use the default internal network - * 'goog-internal'. - * - * Generated from protobuf field bool block_external_network = 9; - * @param bool $var - * @return $this - */ - public function setBlockExternalNetwork($var) - { - GPBUtil::checkBool($var); - $this->block_external_network = $var; - - return $this; - } - - /** - * Optional username for logging in to a docker registry. If username - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * username from the Secret Manager. - * - * Generated from protobuf field string username = 10; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Optional username for logging in to a docker registry. If username - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * username from the Secret Manager. - * - * Generated from protobuf field string username = 10; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - - /** - * Optional password for logging in to a docker registry. If password - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * password from the Secret Manager; - * - * Generated from protobuf field string password = 11; - * @return string - */ - public function getPassword() - { - return $this->password; - } - - /** - * Optional password for logging in to a docker registry. If password - * matches `projects/*/secrets/*/versions/*` then Batch will read the - * password from the Secret Manager; - * - * Generated from protobuf field string password = 11; - * @param string $var - * @return $this - */ - public function setPassword($var) - { - GPBUtil::checkString($var, True); - $this->password = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Container::class, \Google\Cloud\Batch\V1\Runnable_Container::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Script.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Script.php deleted file mode 100644 index ea9a5725b610..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable/Script.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.batch.v1.Runnable.Script - */ -class Script extends \Google\Protobuf\Internal\Message -{ - protected $command; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path - * Script file path on the host VM. - * To specify an interpreter, please add a `#!`(also known as - * [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the - * first line of the file.(For example, to execute the script using bash, - * `#!/bin/bash` should be the first line of the file. To execute the - * script using`Python3`, `#!/usr/bin/env python3` should be the first - * line of the file.) Otherwise, the file will by default be excuted by - * `/bin/sh`. - * @type string $text - * Shell script text. - * To specify an interpreter, please add a `#!\n` at the - * beginning of the text.(For example, to execute the script using bash, - * `#!/bin/bash\n` should be added. To execute the script using`Python3`, - * `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will - * by default be excuted by `/bin/sh`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Script file path on the host VM. - * To specify an interpreter, please add a `#!`(also known as - * [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the - * first line of the file.(For example, to execute the script using bash, - * `#!/bin/bash` should be the first line of the file. To execute the - * script using`Python3`, `#!/usr/bin/env python3` should be the first - * line of the file.) Otherwise, the file will by default be excuted by - * `/bin/sh`. - * - * Generated from protobuf field string path = 1; - * @return string - */ - public function getPath() - { - return $this->readOneof(1); - } - - public function hasPath() - { - return $this->hasOneof(1); - } - - /** - * Script file path on the host VM. - * To specify an interpreter, please add a `#!`(also known as - * [shebang line](https://en.wikipedia.org/wiki/Shebang_(Unix))) as the - * first line of the file.(For example, to execute the script using bash, - * `#!/bin/bash` should be the first line of the file. To execute the - * script using`Python3`, `#!/usr/bin/env python3` should be the first - * line of the file.) Otherwise, the file will by default be excuted by - * `/bin/sh`. - * - * Generated from protobuf field string path = 1; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Shell script text. - * To specify an interpreter, please add a `#!\n` at the - * beginning of the text.(For example, to execute the script using bash, - * `#!/bin/bash\n` should be added. To execute the script using`Python3`, - * `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will - * by default be excuted by `/bin/sh`. - * - * Generated from protobuf field string text = 2; - * @return string - */ - public function getText() - { - return $this->readOneof(2); - } - - public function hasText() - { - return $this->hasOneof(2); - } - - /** - * Shell script text. - * To specify an interpreter, please add a `#!\n` at the - * beginning of the text.(For example, to execute the script using bash, - * `#!/bin/bash\n` should be added. To execute the script using`Python3`, - * `#!/usr/bin/env python3\n` should be added.) Otherwise, the script will - * by default be excuted by `/bin/sh`. - * - * Generated from protobuf field string text = 2; - * @param string $var - * @return $this - */ - public function setText($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getCommand() - { - return $this->whichOneof("command"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Script::class, \Google\Cloud\Batch\V1\Runnable_Script::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Barrier.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Barrier.php deleted file mode 100644 index 795138775fad..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Runnable_Barrier.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.ServiceAccount - */ -class ServiceAccount extends \Google\Protobuf\Internal\Message -{ - /** - * Email address of the service account. If not specified, the default - * Compute Engine service account for the project will be used. If instance - * template is being used, the service account has to be specified in the - * instance template and it has to match the email field here. - * - * Generated from protobuf field string email = 1; - */ - protected $email = ''; - /** - * List of scopes to be enabled for this service account on the VM, in - * addition to the cloud-platform API scope that will be added by default. - * - * Generated from protobuf field repeated string scopes = 2; - */ - private $scopes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $email - * Email address of the service account. If not specified, the default - * Compute Engine service account for the project will be used. If instance - * template is being used, the service account has to be specified in the - * instance template and it has to match the email field here. - * @type array|\Google\Protobuf\Internal\RepeatedField $scopes - * List of scopes to be enabled for this service account on the VM, in - * addition to the cloud-platform API scope that will be added by default. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Email address of the service account. If not specified, the default - * Compute Engine service account for the project will be used. If instance - * template is being used, the service account has to be specified in the - * instance template and it has to match the email field here. - * - * Generated from protobuf field string email = 1; - * @return string - */ - public function getEmail() - { - return $this->email; - } - - /** - * Email address of the service account. If not specified, the default - * Compute Engine service account for the project will be used. If instance - * template is being used, the service account has to be specified in the - * instance template and it has to match the email field here. - * - * Generated from protobuf field string email = 1; - * @param string $var - * @return $this - */ - public function setEmail($var) - { - GPBUtil::checkString($var, True); - $this->email = $var; - - return $this; - } - - /** - * List of scopes to be enabled for this service account on the VM, in - * addition to the cloud-platform API scope that will be added by default. - * - * Generated from protobuf field repeated string scopes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getScopes() - { - return $this->scopes; - } - - /** - * List of scopes to be enabled for this service account on the VM, in - * addition to the cloud-platform API scope that will be added by default. - * - * Generated from protobuf field repeated string scopes = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setScopes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->scopes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/StatusEvent.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/StatusEvent.php deleted file mode 100644 index 293cb8c7bc93..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/StatusEvent.php +++ /dev/null @@ -1,223 +0,0 @@ -google.cloud.batch.v1.StatusEvent - */ -class StatusEvent extends \Google\Protobuf\Internal\Message -{ - /** - * Type of the event. - * - * Generated from protobuf field string type = 3; - */ - protected $type = ''; - /** - * Description of the event. - * - * Generated from protobuf field string description = 1; - */ - protected $description = ''; - /** - * The time this event occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 2; - */ - protected $event_time = null; - /** - * Task Execution - * - * Generated from protobuf field .google.cloud.batch.v1.TaskExecution task_execution = 4; - */ - protected $task_execution = null; - /** - * Task State - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State task_state = 5; - */ - protected $task_state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * Type of the event. - * @type string $description - * Description of the event. - * @type \Google\Protobuf\Timestamp $event_time - * The time this event occurred. - * @type \Google\Cloud\Batch\V1\TaskExecution $task_execution - * Task Execution - * @type int $task_state - * Task State - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Type of the event. - * - * Generated from protobuf field string type = 3; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Type of the event. - * - * Generated from protobuf field string type = 3; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Description of the event. - * - * Generated from protobuf field string description = 1; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the event. - * - * Generated from protobuf field string description = 1; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The time this event occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEventTime() - { - return $this->event_time; - } - - public function hasEventTime() - { - return isset($this->event_time); - } - - public function clearEventTime() - { - unset($this->event_time); - } - - /** - * The time this event occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEventTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->event_time = $var; - - return $this; - } - - /** - * Task Execution - * - * Generated from protobuf field .google.cloud.batch.v1.TaskExecution task_execution = 4; - * @return \Google\Cloud\Batch\V1\TaskExecution|null - */ - public function getTaskExecution() - { - return $this->task_execution; - } - - public function hasTaskExecution() - { - return isset($this->task_execution); - } - - public function clearTaskExecution() - { - unset($this->task_execution); - } - - /** - * Task Execution - * - * Generated from protobuf field .google.cloud.batch.v1.TaskExecution task_execution = 4; - * @param \Google\Cloud\Batch\V1\TaskExecution $var - * @return $this - */ - public function setTaskExecution($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\TaskExecution::class); - $this->task_execution = $var; - - return $this; - } - - /** - * Task State - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State task_state = 5; - * @return int - */ - public function getTaskState() - { - return $this->task_state; - } - - /** - * Task State - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State task_state = 5; - * @param int $var - * @return $this - */ - public function setTaskState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\TaskStatus\State::class); - $this->task_state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Task.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Task.php deleted file mode 100644 index c034a667462e..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/Task.php +++ /dev/null @@ -1,123 +0,0 @@ -google.cloud.batch.v1.Task - */ -class Task extends \Google\Protobuf\Internal\Message -{ - /** - * Task name. - * The name is generated from the parent TaskGroup name and 'id' field. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01/tasks/task01". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Task Status. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus status = 2; - */ - protected $status = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Task name. - * The name is generated from the parent TaskGroup name and 'id' field. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01/tasks/task01". - * @type \Google\Cloud\Batch\V1\TaskStatus $status - * Task Status. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Task name. - * The name is generated from the parent TaskGroup name and 'id' field. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01/tasks/task01". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Task name. - * The name is generated from the parent TaskGroup name and 'id' field. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01/tasks/task01". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Task Status. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus status = 2; - * @return \Google\Cloud\Batch\V1\TaskStatus|null - */ - public function getStatus() - { - return $this->status; - } - - public function hasStatus() - { - return isset($this->status); - } - - public function clearStatus() - { - unset($this->status); - } - - /** - * Task Status. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus status = 2; - * @param \Google\Cloud\Batch\V1\TaskStatus $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\TaskStatus::class); - $this->status = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskExecution.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskExecution.php deleted file mode 100644 index f8c79be6c535..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskExecution.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.batch.v1.TaskExecution - */ -class TaskExecution extends \Google\Protobuf\Internal\Message -{ - /** - * When task is completed as the status of FAILED or SUCCEEDED, - * exit code is for one task execution result, default is 0 as success. - * - * Generated from protobuf field int32 exit_code = 1; - */ - protected $exit_code = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $exit_code - * When task is completed as the status of FAILED or SUCCEEDED, - * exit code is for one task execution result, default is 0 as success. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * When task is completed as the status of FAILED or SUCCEEDED, - * exit code is for one task execution result, default is 0 as success. - * - * Generated from protobuf field int32 exit_code = 1; - * @return int - */ - public function getExitCode() - { - return $this->exit_code; - } - - /** - * When task is completed as the status of FAILED or SUCCEEDED, - * exit code is for one task execution result, default is 0 as success. - * - * Generated from protobuf field int32 exit_code = 1; - * @param int $var - * @return $this - */ - public function setExitCode($var) - { - GPBUtil::checkInt32($var); - $this->exit_code = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskGroup.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskGroup.php deleted file mode 100644 index c1d66ac65511..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskGroup.php +++ /dev/null @@ -1,388 +0,0 @@ -google.cloud.batch.v1.TaskGroup - */ -class TaskGroup extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. TaskGroup name. - * The system generates this field based on parent Job name. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. Tasks in the group share the same task spec. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskSpec task_spec = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $task_spec = null; - /** - * Number of Tasks in the TaskGroup. - * default is 1 - * - * Generated from protobuf field int64 task_count = 4; - */ - protected $task_count = 0; - /** - * Max number of tasks that can run in parallel. - * Default to min(task_count, 1000). - * - * Generated from protobuf field int64 parallelism = 5; - */ - protected $parallelism = 0; - /** - * An array of environment variable mappings, which are passed to Tasks with - * matching indices. If task_environments is used then task_count should - * not be specified in the request (and will be ignored). Task count will be - * the length of task_environments. - * Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in - * addition to any environment variables set in task_environments, specifying - * the number of Tasks in the Task's parent TaskGroup, and the specific Task's - * index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). - * task_environments supports up to 200 entries. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Environment task_environments = 9; - */ - private $task_environments; - /** - * Max number of tasks that can be run on a VM at the same time. - * If not specified, the system will decide a value based on available - * compute resources on a VM and task requirements. - * - * Generated from protobuf field int64 task_count_per_node = 10; - */ - protected $task_count_per_node = 0; - /** - * When true, Batch will populate a file with a list of all VMs assigned to - * the TaskGroup and set the BATCH_HOSTS_FILE environment variable to the path - * of that file. Defaults to false. - * - * Generated from protobuf field bool require_hosts_file = 11; - */ - protected $require_hosts_file = false; - /** - * When true, Batch will configure SSH to allow passwordless login between - * VMs running the Batch tasks in the same TaskGroup. - * - * Generated from protobuf field bool permissive_ssh = 12; - */ - protected $permissive_ssh = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. TaskGroup name. - * The system generates this field based on parent Job name. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01". - * @type \Google\Cloud\Batch\V1\TaskSpec $task_spec - * Required. Tasks in the group share the same task spec. - * @type int|string $task_count - * Number of Tasks in the TaskGroup. - * default is 1 - * @type int|string $parallelism - * Max number of tasks that can run in parallel. - * Default to min(task_count, 1000). - * @type array<\Google\Cloud\Batch\V1\Environment>|\Google\Protobuf\Internal\RepeatedField $task_environments - * An array of environment variable mappings, which are passed to Tasks with - * matching indices. If task_environments is used then task_count should - * not be specified in the request (and will be ignored). Task count will be - * the length of task_environments. - * Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in - * addition to any environment variables set in task_environments, specifying - * the number of Tasks in the Task's parent TaskGroup, and the specific Task's - * index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). - * task_environments supports up to 200 entries. - * @type int|string $task_count_per_node - * Max number of tasks that can be run on a VM at the same time. - * If not specified, the system will decide a value based on available - * compute resources on a VM and task requirements. - * @type bool $require_hosts_file - * When true, Batch will populate a file with a list of all VMs assigned to - * the TaskGroup and set the BATCH_HOSTS_FILE environment variable to the path - * of that file. Defaults to false. - * @type bool $permissive_ssh - * When true, Batch will configure SSH to allow passwordless login between - * VMs running the Batch tasks in the same TaskGroup. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Job::initOnce(); - parent::__construct($data); - } - - /** - * Output only. TaskGroup name. - * The system generates this field based on parent Job name. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. TaskGroup name. - * The system generates this field based on parent Job name. - * For example: - * "projects/123456/locations/us-west1/jobs/job01/taskGroups/group01". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Tasks in the group share the same task spec. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskSpec task_spec = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Batch\V1\TaskSpec|null - */ - public function getTaskSpec() - { - return $this->task_spec; - } - - public function hasTaskSpec() - { - return isset($this->task_spec); - } - - public function clearTaskSpec() - { - unset($this->task_spec); - } - - /** - * Required. Tasks in the group share the same task spec. - * - * Generated from protobuf field .google.cloud.batch.v1.TaskSpec task_spec = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Batch\V1\TaskSpec $var - * @return $this - */ - public function setTaskSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\TaskSpec::class); - $this->task_spec = $var; - - return $this; - } - - /** - * Number of Tasks in the TaskGroup. - * default is 1 - * - * Generated from protobuf field int64 task_count = 4; - * @return int|string - */ - public function getTaskCount() - { - return $this->task_count; - } - - /** - * Number of Tasks in the TaskGroup. - * default is 1 - * - * Generated from protobuf field int64 task_count = 4; - * @param int|string $var - * @return $this - */ - public function setTaskCount($var) - { - GPBUtil::checkInt64($var); - $this->task_count = $var; - - return $this; - } - - /** - * Max number of tasks that can run in parallel. - * Default to min(task_count, 1000). - * - * Generated from protobuf field int64 parallelism = 5; - * @return int|string - */ - public function getParallelism() - { - return $this->parallelism; - } - - /** - * Max number of tasks that can run in parallel. - * Default to min(task_count, 1000). - * - * Generated from protobuf field int64 parallelism = 5; - * @param int|string $var - * @return $this - */ - public function setParallelism($var) - { - GPBUtil::checkInt64($var); - $this->parallelism = $var; - - return $this; - } - - /** - * An array of environment variable mappings, which are passed to Tasks with - * matching indices. If task_environments is used then task_count should - * not be specified in the request (and will be ignored). Task count will be - * the length of task_environments. - * Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in - * addition to any environment variables set in task_environments, specifying - * the number of Tasks in the Task's parent TaskGroup, and the specific Task's - * index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). - * task_environments supports up to 200 entries. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Environment task_environments = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTaskEnvironments() - { - return $this->task_environments; - } - - /** - * An array of environment variable mappings, which are passed to Tasks with - * matching indices. If task_environments is used then task_count should - * not be specified in the request (and will be ignored). Task count will be - * the length of task_environments. - * Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in - * addition to any environment variables set in task_environments, specifying - * the number of Tasks in the Task's parent TaskGroup, and the specific Task's - * index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). - * task_environments supports up to 200 entries. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Environment task_environments = 9; - * @param array<\Google\Cloud\Batch\V1\Environment>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTaskEnvironments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\Environment::class); - $this->task_environments = $arr; - - return $this; - } - - /** - * Max number of tasks that can be run on a VM at the same time. - * If not specified, the system will decide a value based on available - * compute resources on a VM and task requirements. - * - * Generated from protobuf field int64 task_count_per_node = 10; - * @return int|string - */ - public function getTaskCountPerNode() - { - return $this->task_count_per_node; - } - - /** - * Max number of tasks that can be run on a VM at the same time. - * If not specified, the system will decide a value based on available - * compute resources on a VM and task requirements. - * - * Generated from protobuf field int64 task_count_per_node = 10; - * @param int|string $var - * @return $this - */ - public function setTaskCountPerNode($var) - { - GPBUtil::checkInt64($var); - $this->task_count_per_node = $var; - - return $this; - } - - /** - * When true, Batch will populate a file with a list of all VMs assigned to - * the TaskGroup and set the BATCH_HOSTS_FILE environment variable to the path - * of that file. Defaults to false. - * - * Generated from protobuf field bool require_hosts_file = 11; - * @return bool - */ - public function getRequireHostsFile() - { - return $this->require_hosts_file; - } - - /** - * When true, Batch will populate a file with a list of all VMs assigned to - * the TaskGroup and set the BATCH_HOSTS_FILE environment variable to the path - * of that file. Defaults to false. - * - * Generated from protobuf field bool require_hosts_file = 11; - * @param bool $var - * @return $this - */ - public function setRequireHostsFile($var) - { - GPBUtil::checkBool($var); - $this->require_hosts_file = $var; - - return $this; - } - - /** - * When true, Batch will configure SSH to allow passwordless login between - * VMs running the Batch tasks in the same TaskGroup. - * - * Generated from protobuf field bool permissive_ssh = 12; - * @return bool - */ - public function getPermissiveSsh() - { - return $this->permissive_ssh; - } - - /** - * When true, Batch will configure SSH to allow passwordless login between - * VMs running the Batch tasks in the same TaskGroup. - * - * Generated from protobuf field bool permissive_ssh = 12; - * @param bool $var - * @return $this - */ - public function setPermissiveSsh($var) - { - GPBUtil::checkBool($var); - $this->permissive_ssh = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskSpec.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskSpec.php deleted file mode 100644 index 0d5eccb981c0..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskSpec.php +++ /dev/null @@ -1,412 +0,0 @@ -google.cloud.batch.v1.TaskSpec - */ -class TaskSpec extends \Google\Protobuf\Internal\Message -{ - /** - * The sequence of scripts or containers to run for this Task. Each Task using - * this TaskSpec executes its list of runnables in order. The Task succeeds if - * all of its runnables either exit with a zero status or any that exit with a - * non-zero status have the ignore_exit_status flag. - * Background runnables are killed automatically (if they have not already - * exited) a short time after all foreground runnables have completed. Even - * though this is likely to result in a non-zero exit status for the - * background runnable, these automatic kills are not treated as Task - * failures. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Runnable runnables = 8; - */ - private $runnables; - /** - * ComputeResource requirements. - * - * Generated from protobuf field .google.cloud.batch.v1.ComputeResource compute_resource = 3; - */ - protected $compute_resource = null; - /** - * Maximum duration the task should run. - * The task will be killed and marked as FAILED if over this limit. - * - * Generated from protobuf field .google.protobuf.Duration max_run_duration = 4; - */ - protected $max_run_duration = null; - /** - * Maximum number of retries on failures. - * The default, 0, which means never retry. - * The valid value range is [0, 10]. - * - * Generated from protobuf field int32 max_retry_count = 5; - */ - protected $max_retry_count = 0; - /** - * Lifecycle management schema when any task in a task group is failed. - * Currently we only support one lifecycle policy. - * When the lifecycle policy condition is met, - * the action in the policy will execute. - * If task execution result does not meet with the defined lifecycle - * policy, we consider it as the default policy. - * Default policy means if the exit code is 0, exit task. - * If task ends with non-zero exit code, retry the task with max_retry_count. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.LifecyclePolicy lifecycle_policies = 9; - */ - private $lifecycle_policies; - /** - * Deprecated: please use environment(non-plural) instead. - * - * Generated from protobuf field map environments = 6 [deprecated = true]; - * @deprecated - */ - private $environments; - /** - * Volumes to mount before running Tasks using this TaskSpec. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Volume volumes = 7; - */ - private $volumes; - /** - * Environment variables to set before running the Task. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 10; - */ - protected $environment = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Batch\V1\Runnable>|\Google\Protobuf\Internal\RepeatedField $runnables - * The sequence of scripts or containers to run for this Task. Each Task using - * this TaskSpec executes its list of runnables in order. The Task succeeds if - * all of its runnables either exit with a zero status or any that exit with a - * non-zero status have the ignore_exit_status flag. - * Background runnables are killed automatically (if they have not already - * exited) a short time after all foreground runnables have completed. Even - * though this is likely to result in a non-zero exit status for the - * background runnable, these automatic kills are not treated as Task - * failures. - * @type \Google\Cloud\Batch\V1\ComputeResource $compute_resource - * ComputeResource requirements. - * @type \Google\Protobuf\Duration $max_run_duration - * Maximum duration the task should run. - * The task will be killed and marked as FAILED if over this limit. - * @type int $max_retry_count - * Maximum number of retries on failures. - * The default, 0, which means never retry. - * The valid value range is [0, 10]. - * @type array<\Google\Cloud\Batch\V1\LifecyclePolicy>|\Google\Protobuf\Internal\RepeatedField $lifecycle_policies - * Lifecycle management schema when any task in a task group is failed. - * Currently we only support one lifecycle policy. - * When the lifecycle policy condition is met, - * the action in the policy will execute. - * If task execution result does not meet with the defined lifecycle - * policy, we consider it as the default policy. - * Default policy means if the exit code is 0, exit task. - * If task ends with non-zero exit code, retry the task with max_retry_count. - * @type array|\Google\Protobuf\Internal\MapField $environments - * Deprecated: please use environment(non-plural) instead. - * @type array<\Google\Cloud\Batch\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $volumes - * Volumes to mount before running Tasks using this TaskSpec. - * @type \Google\Cloud\Batch\V1\Environment $environment - * Environment variables to set before running the Task. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * The sequence of scripts or containers to run for this Task. Each Task using - * this TaskSpec executes its list of runnables in order. The Task succeeds if - * all of its runnables either exit with a zero status or any that exit with a - * non-zero status have the ignore_exit_status flag. - * Background runnables are killed automatically (if they have not already - * exited) a short time after all foreground runnables have completed. Even - * though this is likely to result in a non-zero exit status for the - * background runnable, these automatic kills are not treated as Task - * failures. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Runnable runnables = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRunnables() - { - return $this->runnables; - } - - /** - * The sequence of scripts or containers to run for this Task. Each Task using - * this TaskSpec executes its list of runnables in order. The Task succeeds if - * all of its runnables either exit with a zero status or any that exit with a - * non-zero status have the ignore_exit_status flag. - * Background runnables are killed automatically (if they have not already - * exited) a short time after all foreground runnables have completed. Even - * though this is likely to result in a non-zero exit status for the - * background runnable, these automatic kills are not treated as Task - * failures. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Runnable runnables = 8; - * @param array<\Google\Cloud\Batch\V1\Runnable>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRunnables($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\Runnable::class); - $this->runnables = $arr; - - return $this; - } - - /** - * ComputeResource requirements. - * - * Generated from protobuf field .google.cloud.batch.v1.ComputeResource compute_resource = 3; - * @return \Google\Cloud\Batch\V1\ComputeResource|null - */ - public function getComputeResource() - { - return $this->compute_resource; - } - - public function hasComputeResource() - { - return isset($this->compute_resource); - } - - public function clearComputeResource() - { - unset($this->compute_resource); - } - - /** - * ComputeResource requirements. - * - * Generated from protobuf field .google.cloud.batch.v1.ComputeResource compute_resource = 3; - * @param \Google\Cloud\Batch\V1\ComputeResource $var - * @return $this - */ - public function setComputeResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\ComputeResource::class); - $this->compute_resource = $var; - - return $this; - } - - /** - * Maximum duration the task should run. - * The task will be killed and marked as FAILED if over this limit. - * - * Generated from protobuf field .google.protobuf.Duration max_run_duration = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getMaxRunDuration() - { - return $this->max_run_duration; - } - - public function hasMaxRunDuration() - { - return isset($this->max_run_duration); - } - - public function clearMaxRunDuration() - { - unset($this->max_run_duration); - } - - /** - * Maximum duration the task should run. - * The task will be killed and marked as FAILED if over this limit. - * - * Generated from protobuf field .google.protobuf.Duration max_run_duration = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setMaxRunDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->max_run_duration = $var; - - return $this; - } - - /** - * Maximum number of retries on failures. - * The default, 0, which means never retry. - * The valid value range is [0, 10]. - * - * Generated from protobuf field int32 max_retry_count = 5; - * @return int - */ - public function getMaxRetryCount() - { - return $this->max_retry_count; - } - - /** - * Maximum number of retries on failures. - * The default, 0, which means never retry. - * The valid value range is [0, 10]. - * - * Generated from protobuf field int32 max_retry_count = 5; - * @param int $var - * @return $this - */ - public function setMaxRetryCount($var) - { - GPBUtil::checkInt32($var); - $this->max_retry_count = $var; - - return $this; - } - - /** - * Lifecycle management schema when any task in a task group is failed. - * Currently we only support one lifecycle policy. - * When the lifecycle policy condition is met, - * the action in the policy will execute. - * If task execution result does not meet with the defined lifecycle - * policy, we consider it as the default policy. - * Default policy means if the exit code is 0, exit task. - * If task ends with non-zero exit code, retry the task with max_retry_count. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.LifecyclePolicy lifecycle_policies = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLifecyclePolicies() - { - return $this->lifecycle_policies; - } - - /** - * Lifecycle management schema when any task in a task group is failed. - * Currently we only support one lifecycle policy. - * When the lifecycle policy condition is met, - * the action in the policy will execute. - * If task execution result does not meet with the defined lifecycle - * policy, we consider it as the default policy. - * Default policy means if the exit code is 0, exit task. - * If task ends with non-zero exit code, retry the task with max_retry_count. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.LifecyclePolicy lifecycle_policies = 9; - * @param array<\Google\Cloud\Batch\V1\LifecyclePolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLifecyclePolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\LifecyclePolicy::class); - $this->lifecycle_policies = $arr; - - return $this; - } - - /** - * Deprecated: please use environment(non-plural) instead. - * - * Generated from protobuf field map environments = 6 [deprecated = true]; - * @return \Google\Protobuf\Internal\MapField - * @deprecated - */ - public function getEnvironments() - { - @trigger_error('environments is deprecated.', E_USER_DEPRECATED); - return $this->environments; - } - - /** - * Deprecated: please use environment(non-plural) instead. - * - * Generated from protobuf field map environments = 6 [deprecated = true]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - * @deprecated - */ - public function setEnvironments($var) - { - @trigger_error('environments is deprecated.', E_USER_DEPRECATED); - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->environments = $arr; - - return $this; - } - - /** - * Volumes to mount before running Tasks using this TaskSpec. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Volume volumes = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVolumes() - { - return $this->volumes; - } - - /** - * Volumes to mount before running Tasks using this TaskSpec. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.Volume volumes = 7; - * @param array<\Google\Cloud\Batch\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVolumes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\Volume::class); - $this->volumes = $arr; - - return $this; - } - - /** - * Environment variables to set before running the Task. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 10; - * @return \Google\Cloud\Batch\V1\Environment|null - */ - public function getEnvironment() - { - return $this->environment; - } - - public function hasEnvironment() - { - return isset($this->environment); - } - - public function clearEnvironment() - { - unset($this->environment); - } - - /** - * Environment variables to set before running the Task. - * - * Generated from protobuf field .google.cloud.batch.v1.Environment environment = 10; - * @param \Google\Cloud\Batch\V1\Environment $var - * @return $this - */ - public function setEnvironment($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\Environment::class); - $this->environment = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus.php deleted file mode 100644 index d450092f3978..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.batch.v1.TaskStatus - */ -class TaskStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Task state - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State state = 1; - */ - protected $state = 0; - /** - * Detailed info about why the state is reached. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - */ - private $status_events; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * Task state - * @type array<\Google\Cloud\Batch\V1\StatusEvent>|\Google\Protobuf\Internal\RepeatedField $status_events - * Detailed info about why the state is reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Task::initOnce(); - parent::__construct($data); - } - - /** - * Task state - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State state = 1; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Task state - * - * Generated from protobuf field .google.cloud.batch.v1.TaskStatus.State state = 1; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Batch\V1\TaskStatus\State::class); - $this->state = $var; - - return $this; - } - - /** - * Detailed info about why the state is reached. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getStatusEvents() - { - return $this->status_events; - } - - /** - * Detailed info about why the state is reached. - * - * Generated from protobuf field repeated .google.cloud.batch.v1.StatusEvent status_events = 2; - * @param array<\Google\Cloud\Batch\V1\StatusEvent>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setStatusEvents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Batch\V1\StatusEvent::class); - $this->status_events = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus/State.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus/State.php deleted file mode 100644 index ec4cc65716fe..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus/State.php +++ /dev/null @@ -1,85 +0,0 @@ -google.cloud.batch.v1.TaskStatus.State - */ -class State -{ - /** - * unknown state - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The Task is created and waiting for resources. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * The Task is assigned to at least one VM. - * - * Generated from protobuf enum ASSIGNED = 2; - */ - const ASSIGNED = 2; - /** - * The Task is running. - * - * Generated from protobuf enum RUNNING = 3; - */ - const RUNNING = 3; - /** - * The Task has failed. - * - * Generated from protobuf enum FAILED = 4; - */ - const FAILED = 4; - /** - * The Task has succeeded. - * - * Generated from protobuf enum SUCCEEDED = 5; - */ - const SUCCEEDED = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::ASSIGNED => 'ASSIGNED', - self::RUNNING => 'RUNNING', - self::FAILED => 'FAILED', - self::SUCCEEDED => 'SUCCEEDED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Batch\V1\TaskStatus_State::class); - diff --git a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus_State.php b/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus_State.php deleted file mode 100644 index 4c76fa84ac6b..000000000000 --- a/owl-bot-staging/Batch/v1/proto/src/Google/Cloud/Batch/V1/TaskStatus_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.batch.v1.Volume - */ -class Volume extends \Google\Protobuf\Internal\Message -{ - /** - * The mount path for the volume, e.g. /mnt/disks/share. - * - * Generated from protobuf field string mount_path = 4; - */ - protected $mount_path = ''; - /** - * For Google Cloud Storage (GCS), mount options are the options supported by - * the gcsfuse tool (https://github.com/GoogleCloudPlatform/gcsfuse). - * For existing persistent disks, mount options provided by the - * mount command (https://man7.org/linux/man-pages/man8/mount.8.html) except - * writing are supported. This is due to restrictions of multi-writer mode - * (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms). - * For other attached disks and Network File System (NFS), mount options are - * these supported by the mount command - * (https://man7.org/linux/man-pages/man8/mount.8.html). - * - * Generated from protobuf field repeated string mount_options = 5; - */ - private $mount_options; - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Batch\V1\NFS $nfs - * A Network File System (NFS) volume. For example, a - * Filestore file share. - * @type \Google\Cloud\Batch\V1\GCS $gcs - * A Google Cloud Storage (GCS) volume. - * @type string $device_name - * Device name of an attached disk volume, which should align with a - * device_name specified by - * job.allocation_policy.instances[0].policy.disks[i].device_name or - * defined by the given instance template in - * job.allocation_policy.instances[0].instance_template. - * @type string $mount_path - * The mount path for the volume, e.g. /mnt/disks/share. - * @type array|\Google\Protobuf\Internal\RepeatedField $mount_options - * For Google Cloud Storage (GCS), mount options are the options supported by - * the gcsfuse tool (https://github.com/GoogleCloudPlatform/gcsfuse). - * For existing persistent disks, mount options provided by the - * mount command (https://man7.org/linux/man-pages/man8/mount.8.html) except - * writing are supported. This is due to restrictions of multi-writer mode - * (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms). - * For other attached disks and Network File System (NFS), mount options are - * these supported by the mount command - * (https://man7.org/linux/man-pages/man8/mount.8.html). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Batch\V1\Volume::initOnce(); - parent::__construct($data); - } - - /** - * A Network File System (NFS) volume. For example, a - * Filestore file share. - * - * Generated from protobuf field .google.cloud.batch.v1.NFS nfs = 1; - * @return \Google\Cloud\Batch\V1\NFS|null - */ - public function getNfs() - { - return $this->readOneof(1); - } - - public function hasNfs() - { - return $this->hasOneof(1); - } - - /** - * A Network File System (NFS) volume. For example, a - * Filestore file share. - * - * Generated from protobuf field .google.cloud.batch.v1.NFS nfs = 1; - * @param \Google\Cloud\Batch\V1\NFS $var - * @return $this - */ - public function setNfs($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\NFS::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A Google Cloud Storage (GCS) volume. - * - * Generated from protobuf field .google.cloud.batch.v1.GCS gcs = 3; - * @return \Google\Cloud\Batch\V1\GCS|null - */ - public function getGcs() - { - return $this->readOneof(3); - } - - public function hasGcs() - { - return $this->hasOneof(3); - } - - /** - * A Google Cloud Storage (GCS) volume. - * - * Generated from protobuf field .google.cloud.batch.v1.GCS gcs = 3; - * @param \Google\Cloud\Batch\V1\GCS $var - * @return $this - */ - public function setGcs($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Batch\V1\GCS::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Device name of an attached disk volume, which should align with a - * device_name specified by - * job.allocation_policy.instances[0].policy.disks[i].device_name or - * defined by the given instance template in - * job.allocation_policy.instances[0].instance_template. - * - * Generated from protobuf field string device_name = 6; - * @return string - */ - public function getDeviceName() - { - return $this->readOneof(6); - } - - public function hasDeviceName() - { - return $this->hasOneof(6); - } - - /** - * Device name of an attached disk volume, which should align with a - * device_name specified by - * job.allocation_policy.instances[0].policy.disks[i].device_name or - * defined by the given instance template in - * job.allocation_policy.instances[0].instance_template. - * - * Generated from protobuf field string device_name = 6; - * @param string $var - * @return $this - */ - public function setDeviceName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * The mount path for the volume, e.g. /mnt/disks/share. - * - * Generated from protobuf field string mount_path = 4; - * @return string - */ - public function getMountPath() - { - return $this->mount_path; - } - - /** - * The mount path for the volume, e.g. /mnt/disks/share. - * - * Generated from protobuf field string mount_path = 4; - * @param string $var - * @return $this - */ - public function setMountPath($var) - { - GPBUtil::checkString($var, True); - $this->mount_path = $var; - - return $this; - } - - /** - * For Google Cloud Storage (GCS), mount options are the options supported by - * the gcsfuse tool (https://github.com/GoogleCloudPlatform/gcsfuse). - * For existing persistent disks, mount options provided by the - * mount command (https://man7.org/linux/man-pages/man8/mount.8.html) except - * writing are supported. This is due to restrictions of multi-writer mode - * (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms). - * For other attached disks and Network File System (NFS), mount options are - * these supported by the mount command - * (https://man7.org/linux/man-pages/man8/mount.8.html). - * - * Generated from protobuf field repeated string mount_options = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMountOptions() - { - return $this->mount_options; - } - - /** - * For Google Cloud Storage (GCS), mount options are the options supported by - * the gcsfuse tool (https://github.com/GoogleCloudPlatform/gcsfuse). - * For existing persistent disks, mount options provided by the - * mount command (https://man7.org/linux/man-pages/man8/mount.8.html) except - * writing are supported. This is due to restrictions of multi-writer mode - * (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms). - * For other attached disks and Network File System (NFS), mount options are - * these supported by the mount command - * (https://man7.org/linux/man-pages/man8/mount.8.html). - * - * Generated from protobuf field repeated string mount_options = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMountOptions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->mount_options = $arr; - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/create_job.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/create_job.php deleted file mode 100644 index ec427d1eab7a..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/create_job.php +++ /dev/null @@ -1,81 +0,0 @@ -setTaskSpec($jobTaskGroupsTaskSpec); - $jobTaskGroups = [$taskGroup,]; - $job = (new Job()) - ->setTaskGroups($jobTaskGroups); - $request = (new CreateJobRequest()) - ->setParent($formattedParent) - ->setJob($job); - - // Call the API and handle any network failures. - try { - /** @var Job $response */ - $response = $batchServiceClient->createJob($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 = BatchServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - create_job_sample($formattedParent); -} -// [END batch_v1_generated_BatchService_CreateJob_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/delete_job.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/delete_job.php deleted file mode 100644 index 83fd3caf9e06..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/delete_job.php +++ /dev/null @@ -1,66 +0,0 @@ -deleteJob($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()); - } -} -// [END batch_v1_generated_BatchService_DeleteJob_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_job.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_job.php deleted file mode 100644 index e613eb84f5cd..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_job.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Job $response */ - $response = $batchServiceClient->getJob($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = BatchServiceClient::jobName('[PROJECT]', '[LOCATION]', '[JOB]'); - - get_job_sample($formattedName); -} -// [END batch_v1_generated_BatchService_GetJob_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_location.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_location.php deleted file mode 100644 index de1d78be3535..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END batch_v1_generated_BatchService_GetLocation_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_task.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_task.php deleted file mode 100644 index 1031d62a019a..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/get_task.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Task $response */ - $response = $batchServiceClient->getTask($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = BatchServiceClient::taskName( - '[PROJECT]', - '[LOCATION]', - '[JOB]', - '[TASK_GROUP]', - '[TASK]' - ); - - get_task_sample($formattedName); -} -// [END batch_v1_generated_BatchService_GetTask_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_jobs.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_jobs.php deleted file mode 100644 index 21437729f2be..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_jobs.php +++ /dev/null @@ -1,62 +0,0 @@ -listJobs($request); - - /** @var Job $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END batch_v1_generated_BatchService_ListJobs_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_locations.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_locations.php deleted file mode 100644 index 38165f54ccad..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END batch_v1_generated_BatchService_ListLocations_sync] diff --git a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_tasks.php b/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_tasks.php deleted file mode 100644 index ffff8c48ff7d..000000000000 --- a/owl-bot-staging/Batch/v1/samples/V1/BatchServiceClient/list_tasks.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $batchServiceClient->listTasks($request); - - /** @var Task $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = BatchServiceClient::taskGroupName( - '[PROJECT]', - '[LOCATION]', - '[JOB]', - '[TASK_GROUP]' - ); - - list_tasks_sample($formattedParent); -} -// [END batch_v1_generated_BatchService_ListTasks_sync] diff --git a/owl-bot-staging/Batch/v1/src/V1/BatchServiceClient.php b/owl-bot-staging/Batch/v1/src/V1/BatchServiceClient.php deleted file mode 100644 index 8ce48d079257..000000000000 --- a/owl-bot-staging/Batch/v1/src/V1/BatchServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $job = new Job(); - * $response = $batchServiceClient->createJob($formattedParent, $job); - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * 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. - */ -class BatchServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.batch.v1.BatchService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'batch.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $jobNameTemplate; - - private static $locationNameTemplate; - - private static $taskNameTemplate; - - private static $taskGroupNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/batch_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/batch_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/batch_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/batch_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getJobNameTemplate() - { - if (self::$jobNameTemplate == null) { - self::$jobNameTemplate = new PathTemplate('projects/{project}/locations/{location}/jobs/{job}'); - } - - return self::$jobNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getTaskNameTemplate() - { - if (self::$taskNameTemplate == null) { - self::$taskNameTemplate = new PathTemplate('projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}/tasks/{task}'); - } - - return self::$taskNameTemplate; - } - - private static function getTaskGroupNameTemplate() - { - if (self::$taskGroupNameTemplate == null) { - self::$taskGroupNameTemplate = new PathTemplate('projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}'); - } - - return self::$taskGroupNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'job' => self::getJobNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'task' => self::getTaskNameTemplate(), - 'taskGroup' => self::getTaskGroupNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a job - * resource. - * - * @param string $project - * @param string $location - * @param string $job - * - * @return string The formatted job resource. - */ - public static function jobName($project, $location, $job) - { - return self::getJobNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'job' => $job, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a task - * resource. - * - * @param string $project - * @param string $location - * @param string $job - * @param string $taskGroup - * @param string $task - * - * @return string The formatted task resource. - */ - public static function taskName($project, $location, $job, $taskGroup, $task) - { - return self::getTaskNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'job' => $job, - 'task_group' => $taskGroup, - 'task' => $task, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a task_group - * resource. - * - * @param string $project - * @param string $location - * @param string $job - * @param string $taskGroup - * - * @return string The formatted task_group resource. - */ - public static function taskGroupName($project, $location, $job, $taskGroup) - { - return self::getTaskGroupNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'job' => $job, - 'task_group' => $taskGroup, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - job: projects/{project}/locations/{location}/jobs/{job} - * - location: projects/{project}/locations/{location} - * - task: projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}/tasks/{task} - * - taskGroup: projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'batch.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Create a Job. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $formattedParent = $batchServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $job = new Job(); - * $response = $batchServiceClient->createJob($formattedParent, $job); - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource name where the Job will be created. - * Pattern: "projects/{project}/locations/{location}" - * @param Job $job Required. The Job to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $jobId - * ID used to uniquely identify the Job within its parent scope. - * This field should contain at most 63 characters and must start with - * lowercase characters. - * Only lowercase characters, numbers and '-' are accepted. - * The '-' character cannot be the first or the last one. - * A system generated ID will be used if the field is not set. - * - * The job.name field in the request will be ignored and the created resource - * name of the Job will be "{parent}/jobs/{job_id}". - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Batch\V1\Job - * - * @throws ApiException if the remote call fails - */ - public function createJob($parent, $job, array $optionalArgs = []) - { - $request = new CreateJobRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setJob($job); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['jobId'])) { - $request->setJobId($optionalArgs['jobId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateJob', Job::class, $optionalArgs, $request)->wait(); - } - - /** - * Delete a Job. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $operationResponse = $batchServiceClient->deleteJob(); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $batchServiceClient->deleteJob(); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $batchServiceClient->resumeOperation($operationName, 'deleteJob'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Job name. - * @type string $reason - * Optional. Reason for this deletion. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and - * the request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteJob(array $optionalArgs = []) - { - $request = new DeleteJobRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['reason'])) { - $request->setReason($optionalArgs['reason']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteJob', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Get a Job specified by its resource name. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $formattedName = $batchServiceClient->jobName('[PROJECT]', '[LOCATION]', '[JOB]'); - * $response = $batchServiceClient->getJob($formattedName); - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Job name. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Batch\V1\Job - * - * @throws ApiException if the remote call fails - */ - public function getJob($name, array $optionalArgs = []) - { - $request = new GetJobRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetJob', Job::class, $optionalArgs, $request)->wait(); - } - - /** - * Return a single Task. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $formattedName = $batchServiceClient->taskName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]', '[TASK]'); - * $response = $batchServiceClient->getTask($formattedName); - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Task name. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Batch\V1\Task - * - * @throws ApiException if the remote call fails - */ - public function getTask($name, array $optionalArgs = []) - { - $request = new GetTaskRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetTask', Task::class, $optionalArgs, $request)->wait(); - } - - /** - * List all Jobs for a project within a region. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $batchServiceClient->listJobs(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $batchServiceClient->listJobs(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * Parent path. - * @type string $filter - * List filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listJobs(array $optionalArgs = []) - { - $request = new ListJobsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListJobs', $optionalArgs, ListJobsResponse::class, $request); - } - - /** - * List Tasks associated with a job. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $formattedParent = $batchServiceClient->taskGroupName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]'); - * // Iterate over pages of elements - * $pagedResponse = $batchServiceClient->listTasks($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $batchServiceClient->listTasks($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of a TaskGroup from which Tasks are being requested. - * Pattern: - * "projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}" - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Task filter, null filter matches all Tasks. - * Filter string should be of the format State=TaskStatus.State e.g. - * State=RUNNING - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listTasks($parent, array $optionalArgs = []) - { - $request = new ListTasksRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListTasks', $optionalArgs, ListTasksResponse::class, $request); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * $response = $batchServiceClient->getLocation(); - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $batchServiceClient = new BatchServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $batchServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $batchServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $batchServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } -} diff --git a/owl-bot-staging/Batch/v1/src/V1/gapic_metadata.json b/owl-bot-staging/Batch/v1/src/V1/gapic_metadata.json deleted file mode 100644 index eae7f15d2f08..000000000000 --- a/owl-bot-staging/Batch/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.batch.v1", - "libraryPackage": "Google\\Cloud\\Batch\\V1", - "services": { - "BatchService": { - "clients": { - "grpc": { - "libraryClient": "BatchServiceGapicClient", - "rpcs": { - "CreateJob": { - "methods": [ - "createJob" - ] - }, - "DeleteJob": { - "methods": [ - "deleteJob" - ] - }, - "GetJob": { - "methods": [ - "getJob" - ] - }, - "GetTask": { - "methods": [ - "getTask" - ] - }, - "ListJobs": { - "methods": [ - "listJobs" - ] - }, - "ListTasks": { - "methods": [ - "listTasks" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_client_config.json b/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_client_config.json deleted file mode 100644 index 4fae7bea9f19..000000000000 --- a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_client_config.json +++ /dev/null @@ -1,84 +0,0 @@ -{ - "interfaces": { - "google.cloud.batch.v1.BatchService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateJob": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteJob": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetJob": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetTask": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListJobs": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListTasks": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_descriptor_config.php b/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_descriptor_config.php deleted file mode 100644 index 3b05da1b865f..000000000000 --- a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_descriptor_config.php +++ /dev/null @@ -1,143 +0,0 @@ - [ - 'google.cloud.batch.v1.BatchService' => [ - 'DeleteJob' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Batch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'CreateJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Batch\V1\Job', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetJob' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Batch\V1\Job', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetTask' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Batch\V1\Task', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListJobs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getJobs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Batch\V1\ListJobsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListTasks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getTasks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Batch\V1\ListTasksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'templateMap' => [ - 'job' => 'projects/{project}/locations/{location}/jobs/{job}', - 'location' => 'projects/{project}/locations/{location}', - 'task' => 'projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}/tasks/{task}', - 'taskGroup' => 'projects/{project}/locations/{location}/jobs/{job}/taskGroups/{task_group}', - ], - ], - ], -]; diff --git a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_rest_client_config.php b/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_rest_client_config.php deleted file mode 100644 index a72321464b81..000000000000 --- a/owl-bot-staging/Batch/v1/src/V1/resources/batch_service_rest_client_config.php +++ /dev/null @@ -1,147 +0,0 @@ - [ - 'google.cloud.batch.v1.BatchService' => [ - 'CreateJob' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/jobs', - 'body' => 'job', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteJob' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/jobs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetJob' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/jobs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetTask' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/jobs/*/taskGroups/*/tasks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListJobs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/jobs', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListTasks' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/jobs/*/taskGroups/*}/tasks', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/Batch/v1/tests/Unit/V1/BatchServiceClientTest.php b/owl-bot-staging/Batch/v1/tests/Unit/V1/BatchServiceClientTest.php deleted file mode 100644 index e679bf004c72..000000000000 --- a/owl-bot-staging/Batch/v1/tests/Unit/V1/BatchServiceClientTest.php +++ /dev/null @@ -1,628 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return BatchServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new BatchServiceClient($options); - } - - /** @test */ - public function createJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $uid = 'uid115792'; - $priority = 1165461084; - $expectedResponse = new Job(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setPriority($priority); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $job = new Job(); - $jobTaskGroups = []; - $job->setTaskGroups($jobTaskGroups); - $response = $gapicClient->createJob($formattedParent, $job); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/CreateJob', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getJob(); - $this->assertProtobufEquals($job, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createJobExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $job = new Job(); - $jobTaskGroups = []; - $job->setTaskGroups($jobTaskGroups); - try { - $gapicClient->createJob($formattedParent, $job); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteJobTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteJobTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteJobTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - $response = $gapicClient->deleteJob(); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/DeleteJob', $actualApiFuncCall); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteJobTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteJobExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteJobTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - $response = $gapicClient->deleteJob(); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteJobTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getJobTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $priority = 1165461084; - $expectedResponse = new Job(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setPriority($priority); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->jobName('[PROJECT]', '[LOCATION]', '[JOB]'); - $response = $gapicClient->getJob($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/GetJob', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getJobExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->jobName('[PROJECT]', '[LOCATION]', '[JOB]'); - try { - $gapicClient->getJob($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Task(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->taskName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]', '[TASK]'); - $response = $gapicClient->getTask($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/GetTask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getTaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->taskName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]', '[TASK]'); - try { - $gapicClient->getTask($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listJobsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $jobsElement = new Job(); - $jobs = [ - $jobsElement, - ]; - $expectedResponse = new ListJobsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setJobs($jobs); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listJobs(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getJobs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/ListJobs', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listJobsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listJobs(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTasksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $tasksElement = new Task(); - $tasks = [ - $tasksElement, - ]; - $expectedResponse = new ListTasksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTasks($tasks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->taskGroupName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]'); - $response = $gapicClient->listTasks($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTasks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.batch.v1.BatchService/ListTasks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listTasksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->taskGroupName('[PROJECT]', '[LOCATION]', '[JOB]', '[TASK_GROUP]'); - try { - $gapicClient->listTasks($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnections/V1/AppConnectionsService.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnections/V1/AppConnectionsService.php deleted file mode 100644 index b5b2b3535b9d821ae50a63488250de472e8b4e46..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6753 zcmb_h&2JmW6%R>CmPWQBk1U&J^RcCkSaPK$qy}iPj*>1v%m|ewR-#y~!^6Ymhj@Rgj5*t!n z;vDN55!s#ynd%X7ZB-*ewN`vUJhi2IYNN`;H%e4|qZo>B$O-X{himr`(hSvg1^7~m zHs0f#pi?BkKfBX3bWLzQ)r0?T>#m}kx~Hp#{x|T!hH#)7E&)k{a}PQuvqYc^c1(>d zEel*GoqOB1z-Jpmpl*%25nR~VG(F;&s?jJDS95gRvz!`Cm83TDLg&+wrDcCxDo#HT zmbi|RG@#^$;5i)<-(3(K;&mMJ9@Co&=!JhZhB#BU^@ePk7WD$eMv@|%A`xdTEEzg6 zz46xE*NM?8l0)@ax18~o?h+qpBP+ROnQfe9xEY(^_!0C!-SR&fQJ4x=7$$#Gz$%OyAdd=s zmm>&9p9zf$YMUr7P)9ZmLMDru=W+_)K!}Zd))Qi8GfX=Buz;oxbOY!h zI}r^oqG`)%5l3luvyv1~4O8B=AzumpJ$e(O6(>_LBeOKS{(;DK9wEA7(wrOU zO_Ti9Q)0SPqh{~|n(delQME(0X%H|dvow=`gl<$x(zStSH_!xS@}ytU$bQZLJ&kfD z*v}&g1q1OH58ONGYSMX%-eLiq;Q`!7bII>4h!^lJ6`Q8Ga5(trelZB-(3N92fZ((v zie(xc2h&WK{Lg@ceVcw7>WudxHtefHGlRK&c0CthAV>`{Br>kapn){fui3yD@COW} z#&ZKPd{Yg>I#G^v*9FFAN#Gm*FEGAL4049?7X(^gKp5CL00#7>w)i?dOQE;ukz^bv zBjUb3e13xFWB9Y22%aJ%sU`H@C>&)uNs6LI45g?Diuv!;=iIuE&&vgH>rk zrKTIMPe6YP!1wCoMSST_NqQ>tO(14tuvG5T6uOqkn?Ou$AjRn^aDfZ}SI;>_gYyJ{ z+*Xc{TwoMRlwTlpC7}Yon&3x94UonfV?2c(VvLK1rEyqOP?%BTJjqeDn9-}Ek zZ4wCB1UoUxV+1T=h`7bXR7}t5^1Qi;F1K{oHq@@dPJrk)bnl)q&88FOzQwjPAEH zmg8n;XuP>2cF`oQ-bofQ<32j~)_YV6m6^d0(WN&0I8nRVS!U30&n>mee0Q#3-;7JdPffQW*?LgR=q( zOIKkkQ3_++mccTb1r#WOuQ&!*7;(ObZoiZ`eM|D|Xo7Bzuc7(+<61@8-`=ZLN}KmL zE9Ln&=xDW6Q+6xW&7Ey|OL?$aoloUf(QGUq@GQzaAzfYr;VWno4)_jF>=`NjK`Q^N zmu_(d&D3Fw+V0My$MdPYf+iUd@FKdpSC{Mk8eK-yrQM2L-`oaGVCzfl7bu&?@M*tR z=ASb3SGlrPVG}3tG@2;y{9${3QtG^rozW{aT!q5o&(PPqg;W2pUcs<<+QC@xXOA}g zu}-{jN&^#J0QBouy7D;A z0P@GgX-3sr2LA%h(cJF13N&~wGyqZAp24@!b-%_VEk#q|mcTF=8!_f%B}4{iDMEDx z1iNs4G6LkBxc=fYT1@!E^=~ime^Lk!_5*kv@*Z67mn^w)a&?##UK->}pZ)mLztivI zb$Zux%DbzL5Gr?L5V_kAjc2mojo}|tkY0VA1ul+3CjE;8BhTF#<>iE3^kh53s(!rR z?LCuOFND8JqlFDgNF6F;YF$>E1b3{h!>xG`ljXONFE6Hr` z`w2zsQ@PMz`@AaKzXm@IX?Mo*(~$Ke`so|)r@eKVAvkHDI9A{X-Ihy=TZ#2;=Wx{j zQfOgFYc!UlhO8gaQKvj3?s7bh`VdRwbD{+04Q(?+Zp=M+D&IV_fcZfd4?WLzr9$E4-k#tE)&X**ZFIyw`-j(p=8@Wh=E+SDQSx)bTtdCZ-VtI`H s{6g2?%`cUE%_)|NzrGV*KCkeXhSgoogle.cloud.beyondcorp.appconnections.v1.AppConnection - */ -class AppConnection extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Unique resource name of the AppConnection. - * The name is ignored when creating a AppConnection. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. An arbitrary user-provided name for the AppConnection. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Required. The type of network connectivity used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Required. Address of the remote application endpoint for the BeyondCorp - * AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.ApplicationEndpoint application_endpoint = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $application_endpoint = null; - /** - * Optional. List of [google.cloud.beyondcorp.v1main.Connector.name] that are - * authorised to be associated with this AppConnection. - * - * Generated from protobuf field repeated string connectors = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $connectors; - /** - * Output only. The current state of the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Optional. Gateway used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway gateway = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $gateway = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Unique resource name of the AppConnection. - * The name is ignored when creating a AppConnection. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp when the resource was last modified. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Resource labels to represent user provided metadata. - * @type string $display_name - * Optional. An arbitrary user-provided name for the AppConnection. Cannot - * exceed 64 characters. - * @type string $uid - * Output only. A unique identifier for the instance generated by the - * system. - * @type int $type - * Required. The type of network connectivity used by the AppConnection. - * @type \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint $application_endpoint - * Required. Address of the remote application endpoint for the BeyondCorp - * AppConnection. - * @type array|\Google\Protobuf\Internal\RepeatedField $connectors - * Optional. List of [google.cloud.beyondcorp.v1main.Connector.name] that are - * authorised to be associated with this AppConnection. - * @type int $state - * Output only. The current state of the AppConnection. - * @type \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Gateway $gateway - * Optional. Gateway used by the AppConnection. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Unique resource name of the AppConnection. - * The name is ignored when creating a AppConnection. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Unique resource name of the AppConnection. - * The name is ignored when creating a AppConnection. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Optional. An arbitrary user-provided name for the AppConnection. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. An arbitrary user-provided name for the AppConnection. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Required. The type of network connectivity used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of network connectivity used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. Address of the remote application endpoint for the BeyondCorp - * AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.ApplicationEndpoint application_endpoint = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint|null - */ - public function getApplicationEndpoint() - { - return $this->application_endpoint; - } - - public function hasApplicationEndpoint() - { - return isset($this->application_endpoint); - } - - public function clearApplicationEndpoint() - { - unset($this->application_endpoint); - } - - /** - * Required. Address of the remote application endpoint for the BeyondCorp - * AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.ApplicationEndpoint application_endpoint = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint $var - * @return $this - */ - public function setApplicationEndpoint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\ApplicationEndpoint::class); - $this->application_endpoint = $var; - - return $this; - } - - /** - * Optional. List of [google.cloud.beyondcorp.v1main.Connector.name] that are - * authorised to be associated with this AppConnection. - * - * Generated from protobuf field repeated string connectors = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnectors() - { - return $this->connectors; - } - - /** - * Optional. List of [google.cloud.beyondcorp.v1main.Connector.name] that are - * authorised to be associated with this AppConnection. - * - * Generated from protobuf field repeated string connectors = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnectors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->connectors = $arr; - - return $this; - } - - /** - * Output only. The current state of the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\State::class); - $this->state = $var; - - return $this; - } - - /** - * Optional. Gateway used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway gateway = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Gateway|null - */ - public function getGateway() - { - return $this->gateway; - } - - public function hasGateway() - { - return isset($this->gateway); - } - - public function clearGateway() - { - unset($this->gateway); - } - - /** - * Optional. Gateway used by the AppConnection. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway gateway = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Gateway $var - * @return $this - */ - public function setGateway($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Gateway::class); - $this->gateway = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/ApplicationEndpoint.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/ApplicationEndpoint.php deleted file mode 100644 index cc68ac49a44e..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/ApplicationEndpoint.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnection.ApplicationEndpoint - */ -class ApplicationEndpoint extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Hostname or IP address of the remote application endpoint. - * - * Generated from protobuf field string host = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $host = ''; - /** - * Required. Port of the remote application endpoint. - * - * Generated from protobuf field int32 port = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $port = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $host - * Required. Hostname or IP address of the remote application endpoint. - * @type int $port - * Required. Port of the remote application endpoint. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Hostname or IP address of the remote application endpoint. - * - * Generated from protobuf field string host = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getHost() - { - return $this->host; - } - - /** - * Required. Hostname or IP address of the remote application endpoint. - * - * Generated from protobuf field string host = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setHost($var) - { - GPBUtil::checkString($var, True); - $this->host = $var; - - return $this; - } - - /** - * Required. Port of the remote application endpoint. - * - * Generated from protobuf field int32 port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getPort() - { - return $this->port; - } - - /** - * Required. Port of the remote application endpoint. - * - * Generated from protobuf field int32 port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setPort($var) - { - GPBUtil::checkInt32($var); - $this->port = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ApplicationEndpoint::class, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection_ApplicationEndpoint::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway.php deleted file mode 100644 index 6af8ac8c19f7..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway.php +++ /dev/null @@ -1,181 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway - */ -class Gateway extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The type of hosting used by the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway.Type type = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uri = ''; - /** - * Output only. Ingress port reserved on the gateways for this - * AppConnection, if not specified or zero, the default port is 19443. - * - * Generated from protobuf field int32 ingress_port = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $ingress_port = 0; - /** - * Required. AppGateway name in following format: - * `projects/{project_id}/locations/{location_id}/appgateways/{gateway_id}` - * - * Generated from protobuf field string app_gateway = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $app_gateway = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * Required. The type of hosting used by the gateway. - * @type string $uri - * Output only. Server-defined URI for this resource. - * @type int $ingress_port - * Output only. Ingress port reserved on the gateways for this - * AppConnection, if not specified or zero, the default port is 19443. - * @type string $app_gateway - * Required. AppGateway name in following format: - * `projects/{project_id}/locations/{location_id}/appgateways/{gateway_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The type of hosting used by the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway.Type type = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of hosting used by the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway.Type type = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection\Gateway\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Output only. Ingress port reserved on the gateways for this - * AppConnection, if not specified or zero, the default port is 19443. - * - * Generated from protobuf field int32 ingress_port = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getIngressPort() - { - return $this->ingress_port; - } - - /** - * Output only. Ingress port reserved on the gateways for this - * AppConnection, if not specified or zero, the default port is 19443. - * - * Generated from protobuf field int32 ingress_port = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setIngressPort($var) - { - GPBUtil::checkInt32($var); - $this->ingress_port = $var; - - return $this; - } - - /** - * Required. AppGateway name in following format: - * `projects/{project_id}/locations/{location_id}/appgateways/{gateway_id}` - * - * Generated from protobuf field string app_gateway = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getAppGateway() - { - return $this->app_gateway; - } - - /** - * Required. AppGateway name in following format: - * `projects/{project_id}/locations/{location_id}/appgateways/{gateway_id}` - * - * Generated from protobuf field string app_gateway = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setAppGateway($var) - { - GPBUtil::checkString($var, True); - $this->app_gateway = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Gateway::class, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection_Gateway::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway/Type.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway/Type.php deleted file mode 100644 index 9f600d8afa1b..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Gateway/Type.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnection.Gateway.Type - */ -class Type -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Gateway hosted in a GCP regional managed instance group. - * - * Generated from protobuf enum GCP_REGIONAL_MIG = 1; - */ - const GCP_REGIONAL_MIG = 1; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::GCP_REGIONAL_MIG => 'GCP_REGIONAL_MIG', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection_Gateway_Type::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/State.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/State.php deleted file mode 100644 index 28c1781608b2..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/State.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnection.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * AppConnection is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * AppConnection has been created. - * - * Generated from protobuf enum CREATED = 2; - */ - const CREATED = 2; - /** - * AppConnection's configuration is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * AppConnection is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * AppConnection is down and may be restored in the future. - * This happens when CCFE sends ProjectState = OFF. - * - * Generated from protobuf enum DOWN = 5; - */ - const DOWN = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::CREATED => 'CREATED', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::DOWN => 'DOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection_State::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Type.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Type.php deleted file mode 100644 index d3a6ffd1e4e5..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection/Type.php +++ /dev/null @@ -1,59 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnection.Type - */ -class Type -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * TCP Proxy based BeyondCorp AppConnection. API will default to this if - * unset. - * - * Generated from protobuf enum TCP_PROXY = 1; - */ - const TCP_PROXY = 1; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::TCP_PROXY => 'TCP_PROXY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection_Type::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnectionOperationMetadata.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnectionOperationMetadata.php deleted file mode 100644 index e2ee3aedca33..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnectionOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.AppConnectionOperationMetadata - */ -class AppConnectionOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_ApplicationEndpoint.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_ApplicationEndpoint.php deleted file mode 100644 index e0e7bfe688d9..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/AppConnection_ApplicationEndpoint.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/ListAppConnections', - $argument, - ['\Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single AppConnection. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\GetAppConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetAppConnection(\Google\Cloud\BeyondCorp\AppConnections\V1\GetAppConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/GetAppConnection', - $argument, - ['\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection', 'decode'], - $metadata, $options); - } - - /** - * Creates a new AppConnection in a given project and location. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\CreateAppConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateAppConnection(\Google\Cloud\BeyondCorp\AppConnections\V1\CreateAppConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/CreateAppConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates the parameters of a single AppConnection. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\UpdateAppConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateAppConnection(\Google\Cloud\BeyondCorp\AppConnections\V1\UpdateAppConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/UpdateAppConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single AppConnection. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\DeleteAppConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteAppConnection(\Google\Cloud\BeyondCorp\AppConnections\V1\DeleteAppConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/DeleteAppConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Resolves AppConnections details for a given AppConnector. - * An internal method called by a connector to find AppConnections to connect - * to. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ResolveAppConnections(\Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/ResolveAppConnections', - $argument, - ['\Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/CreateAppConnectionRequest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/CreateAppConnectionRequest.php deleted file mode 100644 index ef54860b1978..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/CreateAppConnectionRequest.php +++ /dev/null @@ -1,295 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.CreateAppConnectionRequest - */ -class CreateAppConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connection_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $app_connection_id = ''; - /** - * Required. A BeyondCorp AppConnection resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $app_connection = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection Required. A BeyondCorp AppConnection resource. - * @param string $appConnectionId Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\CreateAppConnectionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection, string $appConnectionId): self - { - return (new self()) - ->setParent($parent) - ->setAppConnection($appConnection) - ->setAppConnectionId($appConnectionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * @type string $app_connection_id - * Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $app_connection - * Required. A BeyondCorp AppConnection resource. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connection_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getAppConnectionId() - { - return $this->app_connection_id; - } - - /** - * Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connection_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setAppConnectionId($var) - { - GPBUtil::checkString($var, True); - $this->app_connection_id = $var; - - return $this; - } - - /** - * Required. A BeyondCorp AppConnection resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection|null - */ - public function getAppConnection() - { - return $this->app_connection; - } - - public function hasAppConnection() - { - return isset($this->app_connection); - } - - public function clearAppConnection() - { - unset($this->app_connection); - } - - /** - * Required. A BeyondCorp AppConnection resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $var - * @return $this - */ - public function setAppConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection::class); - $this->app_connection = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/DeleteAppConnectionRequest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/DeleteAppConnectionRequest.php deleted file mode 100644 index 33d06fe0c0a5..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/DeleteAppConnectionRequest.php +++ /dev/null @@ -1,198 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.DeleteAppConnectionRequest - */ -class DeleteAppConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $name Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * Please see {@see AppConnectionsServiceClient::appConnectionName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\DeleteAppConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/GetAppConnectionRequest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/GetAppConnectionRequest.php deleted file mode 100644 index cbda1a28657b..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/GetAppConnectionRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.GetAppConnectionRequest - */ -class GetAppConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * Please see {@see AppConnectionsServiceClient::appConnectionName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\GetAppConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsRequest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsRequest.php deleted file mode 100644 index f2beaa7375a7..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsRequest.php +++ /dev/null @@ -1,258 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.ListAppConnectionsRequest - */ -class ListAppConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectionsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectionsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * @type int $page_size - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectionsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * @type string $page_token - * Optional. The next_page_token value returned from a previous - * ListAppConnectionsRequest, if any. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $order_by - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectionsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectionsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectionsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectionsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsResponse.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsResponse.php deleted file mode 100644 index 31f3294ce77d..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ListAppConnectionsResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.ListAppConnectionsResponse - */ -class ListAppConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of BeyondCorp AppConnections in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connections = 1; - */ - private $app_connections; - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection>|\Google\Protobuf\Internal\RepeatedField $app_connections - * A list of BeyondCorp AppConnections in the project. - * @type string $next_page_token - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * A list of locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * A list of BeyondCorp AppConnections in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connections = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAppConnections() - { - return $this->app_connections; - } - - /** - * A list of BeyondCorp AppConnections in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connections = 1; - * @param array<\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAppConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection::class); - $this->app_connections = $arr; - - return $this; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsRequest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsRequest.php deleted file mode 100644 index d35e11b22f80..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsRequest.php +++ /dev/null @@ -1,220 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsRequest - */ -class ResolveAppConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. BeyondCorp Connector name of the connector associated with those - * AppConnections using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $app_connector_id = ''; - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ResolveAppConnectionsResponse.next_page_token] - * to determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The next_page_token value returned from a previous - * ResolveAppConnectionsResponse, if any. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * Please see {@see AppConnectionsServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * @type string $app_connector_id - * Required. BeyondCorp Connector name of the connector associated with those - * AppConnections using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * @type int $page_size - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ResolveAppConnectionsResponse.next_page_token] - * to determine if there are more instances left to be queried. - * @type string $page_token - * Optional. The next_page_token value returned from a previous - * ResolveAppConnectionsResponse, if any. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. BeyondCorp Connector name of the connector associated with those - * AppConnections using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getAppConnectorId() - { - return $this->app_connector_id; - } - - /** - * Required. BeyondCorp Connector name of the connector associated with those - * AppConnections using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setAppConnectorId($var) - { - GPBUtil::checkString($var, True); - $this->app_connector_id = $var; - - return $this; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ResolveAppConnectionsResponse.next_page_token] - * to determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ResolveAppConnectionsResponse.next_page_token] - * to determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The next_page_token value returned from a previous - * ResolveAppConnectionsResponse, if any. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The next_page_token value returned from a previous - * ResolveAppConnectionsResponse, if any. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse.php deleted file mode 100644 index 9c3bf3d32526..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsResponse - */ -class ResolveAppConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of BeyondCorp AppConnections with details in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsResponse.AppConnectionDetails app_connection_details = 1; - */ - private $app_connection_details; - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse\AppConnectionDetails>|\Google\Protobuf\Internal\RepeatedField $app_connection_details - * A list of BeyondCorp AppConnections with details in the project. - * @type string $next_page_token - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * A list of locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * A list of BeyondCorp AppConnections with details in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsResponse.AppConnectionDetails app_connection_details = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAppConnectionDetails() - { - return $this->app_connection_details; - } - - /** - * A list of BeyondCorp AppConnections with details in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsResponse.AppConnectionDetails app_connection_details = 1; - * @param array<\Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse\AppConnectionDetails>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAppConnectionDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse\AppConnectionDetails::class); - $this->app_connection_details = $arr; - - return $this; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse/AppConnectionDetails.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse/AppConnectionDetails.php deleted file mode 100644 index 9ca817de9125..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse/AppConnectionDetails.php +++ /dev/null @@ -1,118 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.ResolveAppConnectionsResponse.AppConnectionDetails - */ -class AppConnectionDetails extends \Google\Protobuf\Internal\Message -{ - /** - * A BeyondCorp AppConnection in the project. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 1; - */ - protected $app_connection = null; - /** - * If type=GCP_REGIONAL_MIG, contains most recent VM instances, like - * `https://www.googleapis.com/compute/v1/projects/{project_id}/zones/{zone_id}/instances/{instance_id}`. - * - * Generated from protobuf field repeated string recent_mig_vms = 2; - */ - private $recent_mig_vms; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $app_connection - * A BeyondCorp AppConnection in the project. - * @type array|\Google\Protobuf\Internal\RepeatedField $recent_mig_vms - * If type=GCP_REGIONAL_MIG, contains most recent VM instances, like - * `https://www.googleapis.com/compute/v1/projects/{project_id}/zones/{zone_id}/instances/{instance_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * A BeyondCorp AppConnection in the project. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 1; - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection|null - */ - public function getAppConnection() - { - return $this->app_connection; - } - - public function hasAppConnection() - { - return isset($this->app_connection); - } - - public function clearAppConnection() - { - unset($this->app_connection); - } - - /** - * A BeyondCorp AppConnection in the project. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 1; - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $var - * @return $this - */ - public function setAppConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection::class); - $this->app_connection = $var; - - return $this; - } - - /** - * If type=GCP_REGIONAL_MIG, contains most recent VM instances, like - * `https://www.googleapis.com/compute/v1/projects/{project_id}/zones/{zone_id}/instances/{instance_id}`. - * - * Generated from protobuf field repeated string recent_mig_vms = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRecentMigVms() - { - return $this->recent_mig_vms; - } - - /** - * If type=GCP_REGIONAL_MIG, contains most recent VM instances, like - * `https://www.googleapis.com/compute/v1/projects/{project_id}/zones/{zone_id}/instances/{instance_id}`. - * - * Generated from protobuf field repeated string recent_mig_vms = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRecentMigVms($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->recent_mig_vms = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AppConnectionDetails::class, \Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse_AppConnectionDetails::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse_AppConnectionDetails.php b/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse_AppConnectionDetails.php deleted file mode 100644 index 5b410d2e879c..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/proto/src/Google/Cloud/BeyondCorp/AppConnections/V1/ResolveAppConnectionsResponse_AppConnectionDetails.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.beyondcorp.appconnections.v1.UpdateAppConnectionRequest - */ -class UpdateAppConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $app_connection = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * @param \Google\Protobuf\FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\UpdateAppConnectionRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $appConnection, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setAppConnection($appConnection) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * @type \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $app_connection - * Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type bool $allow_missing - * Optional. If set as true, will create the resource if it is not found. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnections\V1\AppConnectionsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection|null - */ - public function getAppConnection() - { - return $this->app_connection; - } - - public function hasAppConnection() - { - return isset($this->app_connection); - } - - public function clearAppConnection() - { - unset($this->app_connection); - } - - /** - * Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnections.v1.AppConnection app_connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection $var - * @return $this - */ - public function setAppConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection::class); - $this->app_connection = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/create_app_connection.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/create_app_connection.php deleted file mode 100644 index 9ae156f93cb2..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/create_app_connection.php +++ /dev/null @@ -1,114 +0,0 @@ -setHost($appConnectionApplicationEndpointHost) - ->setPort($appConnectionApplicationEndpointPort); - $appConnection = (new AppConnection()) - ->setName($appConnectionName) - ->setType($appConnectionType) - ->setApplicationEndpoint($appConnectionApplicationEndpoint); - $request = (new CreateAppConnectionRequest()) - ->setParent($formattedParent) - ->setAppConnection($appConnection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->createAppConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppConnection $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 = AppConnectionsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $appConnectionName = '[NAME]'; - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnectionApplicationEndpointHost = '[HOST]'; - $appConnectionApplicationEndpointPort = 0; - - create_app_connection_sample( - $formattedParent, - $appConnectionName, - $appConnectionType, - $appConnectionApplicationEndpointHost, - $appConnectionApplicationEndpointPort - ); -} -// [END beyondcorp_v1_generated_AppConnectionsService_CreateAppConnection_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/delete_app_connection.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/delete_app_connection.php deleted file mode 100644 index 702bf1ca0a59..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/delete_app_connection.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->deleteAppConnection($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 = AppConnectionsServiceClient::appConnectionName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTION]' - ); - - delete_app_connection_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppConnectionsService_DeleteAppConnection_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_app_connection.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_app_connection.php deleted file mode 100644 index d3545f932a5d..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_app_connection.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var AppConnection $response */ - $response = $appConnectionsServiceClient->getAppConnection($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 = AppConnectionsServiceClient::appConnectionName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTION]' - ); - - get_app_connection_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppConnectionsService_GetAppConnection_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_iam_policy.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_iam_policy.php deleted file mode 100644 index c8960b0cbc2c..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appConnectionsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectionsService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_location.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_location.php deleted file mode 100644 index 409b97e6664e..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppConnectionsService_GetLocation_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_app_connections.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_app_connections.php deleted file mode 100644 index 6b545eaf68f9..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_app_connections.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $appConnectionsServiceClient->listAppConnections($request); - - /** @var AppConnection $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 = AppConnectionsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_app_connections_sample($formattedParent); -} -// [END beyondcorp_v1_generated_AppConnectionsService_ListAppConnections_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_locations.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_locations.php deleted file mode 100644 index 50eb717bdcd3..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppConnectionsService_ListLocations_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php deleted file mode 100644 index e33fb8d98a0c..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/resolve_app_connections.php +++ /dev/null @@ -1,91 +0,0 @@ -setParent($formattedParent) - ->setAppConnectorId($formattedAppConnectorId); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $appConnectionsServiceClient->resolveAppConnections($request); - - /** @var AppConnectionDetails $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 = AppConnectionsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $formattedAppConnectorId = AppConnectionsServiceClient::appConnectorName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTOR]' - ); - - resolve_app_connections_sample($formattedParent, $formattedAppConnectorId); -} -// [END beyondcorp_v1_generated_AppConnectionsService_ResolveAppConnections_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/set_iam_policy.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/set_iam_policy.php deleted file mode 100644 index dc90b676041f..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appConnectionsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectionsService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php deleted file mode 100644 index 1da996bb2f54..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $appConnectionsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectionsService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/update_app_connection.php b/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/update_app_connection.php deleted file mode 100644 index 03a58045b9aa..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/samples/V1/AppConnectionsServiceClient/update_app_connection.php +++ /dev/null @@ -1,110 +0,0 @@ -setHost($appConnectionApplicationEndpointHost) - ->setPort($appConnectionApplicationEndpointPort); - $appConnection = (new AppConnection()) - ->setName($appConnectionName) - ->setType($appConnectionType) - ->setApplicationEndpoint($appConnectionApplicationEndpoint); - $request = (new UpdateAppConnectionRequest()) - ->setUpdateMask($updateMask) - ->setAppConnection($appConnection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectionsServiceClient->updateAppConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppConnection $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 -{ - $appConnectionName = '[NAME]'; - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnectionApplicationEndpointHost = '[HOST]'; - $appConnectionApplicationEndpointPort = 0; - - update_app_connection_sample( - $appConnectionName, - $appConnectionType, - $appConnectionApplicationEndpointHost, - $appConnectionApplicationEndpointPort - ); -} -// [END beyondcorp_v1_generated_AppConnectionsService_UpdateAppConnection_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/AppConnectionsServiceClient.php b/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/AppConnectionsServiceClient.php deleted file mode 100644 index 8006704173b9..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/AppConnectionsServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $appConnection = new AppConnection(); - * $operationResponse = $appConnectionsServiceClient->createAppConnection($formattedParent, $appConnection); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectionsServiceClient->createAppConnection($formattedParent, $appConnection); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectionsServiceClient->resumeOperation($operationName, 'createAppConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * 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. - */ -class AppConnectionsServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.beyondcorp.appconnections.v1.AppConnectionsService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'beyondcorp.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $appConnectionNameTemplate; - - private static $appConnectorNameTemplate; - - private static $appGatewayNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/app_connections_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/app_connections_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/app_connections_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/app_connections_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getAppConnectionNameTemplate() - { - if (self::$appConnectionNameTemplate == null) { - self::$appConnectionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/appConnections/{app_connection}'); - } - - return self::$appConnectionNameTemplate; - } - - private static function getAppConnectorNameTemplate() - { - if (self::$appConnectorNameTemplate == null) { - self::$appConnectorNameTemplate = new PathTemplate('projects/{project}/locations/{location}/appConnectors/{app_connector}'); - } - - return self::$appConnectorNameTemplate; - } - - private static function getAppGatewayNameTemplate() - { - if (self::$appGatewayNameTemplate == null) { - self::$appGatewayNameTemplate = new PathTemplate('projects/{project}/locations/{location}/appGateways/{app_gateway}'); - } - - return self::$appGatewayNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'appConnection' => self::getAppConnectionNameTemplate(), - 'appConnector' => self::getAppConnectorNameTemplate(), - 'appGateway' => self::getAppGatewayNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * app_connection resource. - * - * @param string $project - * @param string $location - * @param string $appConnection - * - * @return string The formatted app_connection resource. - */ - public static function appConnectionName($project, $location, $appConnection) - { - return self::getAppConnectionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'app_connection' => $appConnection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * app_connector resource. - * - * @param string $project - * @param string $location - * @param string $appConnector - * - * @return string The formatted app_connector resource. - */ - public static function appConnectorName($project, $location, $appConnector) - { - return self::getAppConnectorNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'app_connector' => $appConnector, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a app_gateway - * resource. - * - * @param string $project - * @param string $location - * @param string $appGateway - * - * @return string The formatted app_gateway resource. - */ - public static function appGatewayName($project, $location, $appGateway) - { - return self::getAppGatewayNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'app_gateway' => $appGateway, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - appConnection: projects/{project}/locations/{location}/appConnections/{app_connection} - * - appConnector: projects/{project}/locations/{location}/appConnectors/{app_connector} - * - appGateway: projects/{project}/locations/{location}/appGateways/{app_gateway} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'beyondcorp.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new AppConnection in a given project and location. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $formattedParent = $appConnectionsServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $appConnection = new AppConnection(); - * $operationResponse = $appConnectionsServiceClient->createAppConnection($formattedParent, $appConnection); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectionsServiceClient->createAppConnection($formattedParent, $appConnection); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectionsServiceClient->resumeOperation($operationName, 'createAppConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource project name of the AppConnection location using the - * form: `projects/{project_id}/locations/{location_id}` - * @param AppConnection $appConnection Required. A BeyondCorp AppConnection resource. - * @param array $optionalArgs { - * Optional. - * - * @type string $appConnectionId - * Optional. User-settable AppConnection resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createAppConnection($parent, $appConnection, array $optionalArgs = []) - { - $request = new CreateAppConnectionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAppConnection($appConnection); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['appConnectionId'])) { - $request->setAppConnectionId($optionalArgs['appConnectionId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateAppConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single AppConnection. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $formattedName = $appConnectionsServiceClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - * $operationResponse = $appConnectionsServiceClient->deleteAppConnection($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectionsServiceClient->deleteAppConnection($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectionsServiceClient->resumeOperation($operationName, 'deleteAppConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteAppConnection($name, array $optionalArgs = []) - { - $request = new DeleteAppConnectionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteAppConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single AppConnection. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $formattedName = $appConnectionsServiceClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - * $response = $appConnectionsServiceClient->getAppConnection($formattedName); - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp AppConnection name using the form: - * `projects/{project_id}/locations/{location_id}/appConnections/{app_connection_id}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection - * - * @throws ApiException if the remote call fails - */ - public function getAppConnection($name, array $optionalArgs = []) - { - $request = new GetAppConnectionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetAppConnection', AppConnection::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists AppConnections in a given project and location. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $formattedParent = $appConnectionsServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $appConnectionsServiceClient->listAppConnections($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appConnectionsServiceClient->listAppConnections($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $orderBy - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listAppConnections($parent, array $optionalArgs = []) - { - $request = new ListAppConnectionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAppConnections', $optionalArgs, ListAppConnectionsResponse::class, $request); - } - - /** - * Resolves AppConnections details for a given AppConnector. - * An internal method called by a connector to find AppConnections to connect - * to. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $formattedParent = $appConnectionsServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $formattedAppConnectorId = $appConnectionsServiceClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - * // Iterate over pages of elements - * $pagedResponse = $appConnectionsServiceClient->resolveAppConnections($formattedParent, $formattedAppConnectorId); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appConnectionsServiceClient->resolveAppConnections($formattedParent, $formattedAppConnectorId); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource name of the AppConnection location using the form: - * `projects/{project_id}/locations/{location_id}` - * @param string $appConnectorId Required. BeyondCorp Connector name of the connector associated with those - * AppConnections using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function resolveAppConnections($parent, $appConnectorId, array $optionalArgs = []) - { - $request = new ResolveAppConnectionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAppConnectorId($appConnectorId); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ResolveAppConnections', $optionalArgs, ResolveAppConnectionsResponse::class, $request); - } - - /** - * Updates the parameters of a single AppConnection. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $appConnection = new AppConnection(); - * $operationResponse = $appConnectionsServiceClient->updateAppConnection($updateMask, $appConnection); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectionsServiceClient->updateAppConnection($updateMask, $appConnection); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectionsServiceClient->resumeOperation($operationName, 'updateAppConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnection]: - * * `labels` - * * `display_name` - * * `application_endpoint` - * * `connectors` - * @param AppConnection $appConnection Required. AppConnection message with updated fields. Only supported fields - * specified in update_mask are updated. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type bool $allowMissing - * Optional. If set as true, will create the resource if it is not found. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateAppConnection($updateMask, $appConnection, array $optionalArgs = []) - { - $request = new UpdateAppConnectionRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setAppConnection($appConnection); - $requestParamHeaders['app_connection.name'] = $appConnection->getName(); - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateAppConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $response = $appConnectionsServiceClient->getLocation(); - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $appConnectionsServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appConnectionsServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $resource = 'resource'; - * $response = $appConnectionsServiceClient->getIamPolicy($resource); - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $appConnectionsServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $appConnectionsServiceClient = new AppConnectionsServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $appConnectionsServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $appConnectionsServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 68ef8018f5ae..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,73 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.beyondcorp.appconnections.v1", - "libraryPackage": "Google\\Cloud\\BeyondCorp\\AppConnections\\V1", - "services": { - "AppConnectionsService": { - "clients": { - "grpc": { - "libraryClient": "AppConnectionsServiceGapicClient", - "rpcs": { - "CreateAppConnection": { - "methods": [ - "createAppConnection" - ] - }, - "DeleteAppConnection": { - "methods": [ - "deleteAppConnection" - ] - }, - "GetAppConnection": { - "methods": [ - "getAppConnection" - ] - }, - "ListAppConnections": { - "methods": [ - "listAppConnections" - ] - }, - "ResolveAppConnections": { - "methods": [ - "resolveAppConnections" - ] - }, - "UpdateAppConnection": { - "methods": [ - "updateAppConnection" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_client_config.json b/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_client_config.json deleted file mode 100644 index 96222a9ebc4f..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_client_config.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "interfaces": { - "google.cloud.beyondcorp.appconnections.v1.AppConnectionsService": { - "retry_codes": { - "no_retry_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - } - }, - "methods": { - "CreateAppConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteAppConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetAppConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListAppConnections": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ResolveAppConnections": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "UpdateAppConnection": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_descriptor_config.php b/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_descriptor_config.php deleted file mode 100644 index 0efddabe3d31..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_descriptor_config.php +++ /dev/null @@ -1,197 +0,0 @@ - [ - 'google.cloud.beyondcorp.appconnections.v1.AppConnectionsService' => [ - 'CreateAppConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateAppConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnections\V1\AppConnectionOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'app_connection.name', - 'fieldAccessors' => [ - 'getAppConnection', - 'getName', - ], - ], - ], - ], - 'GetAppConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\AppConnection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAppConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAppConnections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\ListAppConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ResolveAppConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAppConnectionDetails', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppConnections\V1\ResolveAppConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'appConnection' => 'projects/{project}/locations/{location}/appConnections/{app_connection}', - 'appConnector' => 'projects/{project}/locations/{location}/appConnectors/{app_connector}', - 'appGateway' => 'projects/{project}/locations/{location}/appGateways/{app_gateway}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_rest_client_config.php b/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_rest_client_config.php deleted file mode 100644 index 1094f3784fcd..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/src/V1/resources/app_connections_service_rest_client_config.php +++ /dev/null @@ -1,251 +0,0 @@ - [ - 'google.cloud.beyondcorp.appconnections.v1.AppConnectionsService' => [ - 'CreateAppConnection' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appConnections', - 'body' => 'app_connection', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppConnection' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appConnections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetAppConnection' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appConnections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAppConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appConnections', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ResolveAppConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appConnections:resolve', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateAppConnection' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{app_connection.name=projects/*/locations/*/appConnections/*}', - 'body' => 'app_connection', - 'placeholders' => [ - 'app_connection.name' => [ - 'getters' => [ - 'getAppConnection', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/AppConnectionsServiceClientTest.php b/owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/AppConnectionsServiceClientTest.php deleted file mode 100644 index 0b8ddaf5f80a..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnections/v1/tests/Unit/V1/AppConnectionsServiceClientTest.php +++ /dev/null @@ -1,1001 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AppConnectionsServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AppConnectionsServiceClient($options); - } - - /** @test */ - public function createAppConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnection(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAppConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appConnection = new AppConnection(); - $appConnectionName = 'appConnectionName-1608104182'; - $appConnection->setName($appConnectionName); - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnection->setType($appConnectionType); - $appConnectionApplicationEndpoint = new ApplicationEndpoint(); - $applicationEndpointHost = 'applicationEndpointHost1976079949'; - $appConnectionApplicationEndpoint->setHost($applicationEndpointHost); - $applicationEndpointPort = 1976318246; - $appConnectionApplicationEndpoint->setPort($applicationEndpointPort); - $appConnection->setApplicationEndpoint($appConnectionApplicationEndpoint); - $response = $gapicClient->createAppConnection($formattedParent, $appConnection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/CreateAppConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAppConnection(); - $this->assertProtobufEquals($appConnection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAppConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appConnection = new AppConnection(); - $appConnectionName = 'appConnectionName-1608104182'; - $appConnection->setName($appConnectionName); - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnection->setType($appConnectionType); - $appConnectionApplicationEndpoint = new ApplicationEndpoint(); - $applicationEndpointHost = 'applicationEndpointHost1976079949'; - $appConnectionApplicationEndpoint->setHost($applicationEndpointHost); - $applicationEndpointPort = 1976318246; - $appConnectionApplicationEndpoint->setPort($applicationEndpointPort); - $appConnection->setApplicationEndpoint($appConnectionApplicationEndpoint); - $response = $gapicClient->createAppConnection($formattedParent, $appConnection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteAppConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - $response = $gapicClient->deleteAppConnection($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/DeleteAppConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - $response = $gapicClient->deleteAppConnection($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAppConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnection(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - $response = $gapicClient->getAppConnection($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/GetAppConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAppConnectionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appConnectionName('[PROJECT]', '[LOCATION]', '[APP_CONNECTION]'); - try { - $gapicClient->getAppConnection($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $appConnectionsElement = new AppConnection(); - $appConnections = [ - $appConnectionsElement, - ]; - $expectedResponse = new ListAppConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAppConnections($appConnections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listAppConnections($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAppConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/ListAppConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppConnectionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listAppConnections($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function resolveAppConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $appConnectionDetailsElement = new AppConnectionDetails(); - $appConnectionDetails = [ - $appConnectionDetailsElement, - ]; - $expectedResponse = new ResolveAppConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAppConnectionDetails($appConnectionDetails); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $formattedAppConnectorId = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $response = $gapicClient->resolveAppConnections($formattedParent, $formattedAppConnectorId); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAppConnectionDetails()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/ResolveAppConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getAppConnectorId(); - $this->assertProtobufEquals($formattedAppConnectorId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function resolveAppConnectionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $formattedAppConnectorId = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - try { - $gapicClient->resolveAppConnections($formattedParent, $formattedAppConnectorId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateAppConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnection(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateAppConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $appConnection = new AppConnection(); - $appConnectionName = 'appConnectionName-1608104182'; - $appConnection->setName($appConnectionName); - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnection->setType($appConnectionType); - $appConnectionApplicationEndpoint = new ApplicationEndpoint(); - $applicationEndpointHost = 'applicationEndpointHost1976079949'; - $appConnectionApplicationEndpoint->setHost($applicationEndpointHost); - $applicationEndpointPort = 1976318246; - $appConnectionApplicationEndpoint->setPort($applicationEndpointPort); - $appConnection->setApplicationEndpoint($appConnectionApplicationEndpoint); - $response = $gapicClient->updateAppConnection($updateMask, $appConnection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnections.v1.AppConnectionsService/UpdateAppConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getAppConnection(); - $this->assertProtobufEquals($appConnection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateAppConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateAppConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateAppConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $appConnection = new AppConnection(); - $appConnectionName = 'appConnectionName-1608104182'; - $appConnection->setName($appConnectionName); - $appConnectionType = Type::TYPE_UNSPECIFIED; - $appConnection->setType($appConnectionType); - $appConnectionApplicationEndpoint = new ApplicationEndpoint(); - $applicationEndpointHost = 'applicationEndpointHost1976079949'; - $appConnectionApplicationEndpoint->setHost($applicationEndpointHost); - $applicationEndpointPort = 1976318246; - $appConnectionApplicationEndpoint->setPort($applicationEndpointPort); - $appConnection->setApplicationEndpoint($appConnectionApplicationEndpoint); - $response = $gapicClient->updateAppConnection($updateMask, $appConnection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateAppConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorInstanceConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorInstanceConfig.php deleted file mode 100644 index b82fc926871c931d6c7fabc36850f5f3cbcc0c4d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1743 zcmb_c-A)rh6t=~n3?w8A7Zo**NJ2?qn_|3h0Zj{18x<+1Y8CWIHqN&XQEa zL--mziZ9@;*WURC&d+vRY^z+zP087FzVDnf-}!c5igN*;zy@I?Mv{au=tFre+I(JQQwY)tzXt|~Lsdni%nIthok$*rE98;mT(o(6O z*CjH41sy4GWV9NNc3|1|=y_vJ?m-!+WRxAkn8-9{JEm_9aGC$-PgrP8Q2&sUD6Ern zbU}ISdBdrOAd^b-!D_5Oxyr0!>jljQuZ3Yg=b@5RIqyvOxek8a0dN1OmYlLhbB!|H zp)%cT%5*QPEB7*9qe1mp6~y{hkgH#dU}d_PoCjbrA)ivBh0M}kK;lvX7RodAnIE;H zvjrCaka?-7zRqtiyIF4oMptdo`3RO6m$XB%5+!HZWt3)2$?l-!pX0bkBOq4v&Ks~m zd#F3Ow$g2b`RwMHO!t7&y`|RdaV-`W(!U4C*X{1&LyHpl!1}o35kkB!h@# zQT?QI^{XP-RAzbOG3$?}%gWqVt8n(-zV$%IyjSV+=@yFwwJxiM$!u2yJJ-Z6f~#V= zVa(L-)U{^1uMFEA?I&?htKSBxerCLx^Xg<@Td$Hs#^WpR{aM_!$ew53!t;jMo_8(X g^G>V5tkM3{_1p$Ft(}dy-&E%_nbw~!!6g8{0gEM6{{R30 diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorsService.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/AppConnectorsService.php deleted file mode 100644 index 7392913843a38ae291a923e9dc80171ede49c385..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6117 zcmb_g&2QXP5NCIjG-DxGlDNqQ8$t$F+T1w@tCt?R2m!>h^(SnAnv>v9={{ZtaTo+WPKm zu+_7>u8w7K&$jnWT-Hsy+b*|o&$imS?K)-6adg|VuAqoGBH6HI>A3Wk$YheW z*Bl%0S``Cj8w5gtueomd*tImXS;L<08V&%_fTgm$hy4(EGE#brA4|j;9kIl8l;wny ztD^6AarAUibg|!ct(#PDBH%du)f@t);uuZEvTTBaZF#cXx2Z4UX&bAifh~WuJ+}>P zwkvpFJ2Y%}w5{8ilPtB8rxJxQCnU(a1wey4VW4B|rPuBBQv%J`t&W{u?uKpcxn0XL zti9%zLjrR&7lq8DnBUR72kFla_wE`Hh`x5<4Bt!He*KogxvjL@A(d}Kq9}#rBUF47 z{qhE?zmN2y4*9|t1&NvFS4c-? zX7K^Ag0BeR2v_)l>)C?huNjozFg!mRGu}4-xC;akZlMWBa{=6ZM$D9^D$-*m`=3%0 z-iWw{=?Q-DB)CY*Q8~gTH05Y}SoI+N=CdGTypnsYWQ5BI(Q)5?fUSIv%BB++&_u^D zA*JTW`hyqIr0uq`tG0Ui@o>2KO$N;m(cE(&rp6ml2qdD@`xokeI@!b4-ev zav7bo@F%_+(VG}FC0sz$UCYIqzOS`R494V2Q^kAe(i)Co8bG>&#>h1o2Nb0QwD@@z z%~#b!0kaGNMZhDiX@C9-hH9QMQENd zju_63`x1<+VG|EG?z!kQfHvhXb8SK)qAXYFpA5RNjUC(dcc7r?hRLBmNQYRCNK0t} zfRE)r%D9n$k6y&XSd|j^-_D?!D4&G$u~4OS1#amy{8W-hxvEKSh4(8_Cnxk7Np}%_ zhB0zr*L^f$YAtMf5EdkJRRRj1dOOB4m$X5J)GgobF=x-CnYQ6Mrq)wwD(dG{VGiZG z5Qh_>Ar1PR&_LsGx%oJM2F7NWSDsM`LLJP|(9o>o8kTN2nn`cG{3HdW_Kcz%fiO~t zG5;qxHBC<#A@>h*DpU9=gU-f|5-fC%KX6n{*X=I9Ca0HoUW6qQf7vKZ^an2$UPZI< zG2tv4#|N5W^4nwrjrlzX7p|k}h|`5>lzV`CYz^50d9};9J0)k|%@kEMPTeD1MCW&Q zmEF2}cXOvvudd%-uh-^Y5@yh3b-S+Yu5Yf*WkA{)`UO*2GIh66V^cZuRjY5*>B2E# z5{=ci?r+YG%kC4!PMr_xkfA?<7o}G|;=hi|rmeF&xqKA-JSK0=u*!$Uv8(C0_(c|7 ziAHl+YX|R65|z&Ix%m4TYErf<1Uu(2!+ey!_V;dN~S* z$C)HN&Y<&&DoPk3*CaOcYNSw29|c2XurjV#`RvcXzs|lbERpWQ5i3SlLxwCwn6WUx zh!cg^uEOsbbZ(#;6W&j++`!hryb+Q~6!_x%F^fn7eu_N<1YbBlQE2HXe49l=vIrDL zz&p7+uJ*5|Z`hDEK6Ir^KhnsK3C- zGYTM_`j3Ye^=g4R_g% z6y0)W;Y4{Q&VpFkJSq#{P5vJ4psQZ*Sh{bYX)D3D$?)R z?m^|pELw#3e`-`K^Gfvo=GRe!^i>;~54V|Df~Pw47540>H)KFD)_d;vh@93<04w_a zbGEcbJIzv+bebjBX|6&WJ60}x(!Hfe!O|x0O7pffS=@|u7riDlrk`XNnPgd}qGh=+ rTb5&H%JRLX)&!;Q+i!+#v_;nOjWmc!9bo7~n!|J@YvLZGV}$+(A-*v8 diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/ResourceInfo.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appconnectors/V1/ResourceInfo.php deleted file mode 100644 index a27254573485e4e80f15b7e78eb14c8ab4cdb040..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1587 zcmbtUTW-@p6eUS1?KD8J_(&@uhKHz&ilY>Xk7)~Xo{a=al$QjuR88zjGLqvN+2cw9 zbtkNV4X_7R!8eOQjP2M-`Vg=DIJVC{bMC#z=jaWeaPS1yi9=j0hy{l;C?*7QmkDMv z8xH-^h`7*XQ%-H-Y7kahu-WRtYNgS8BuhQ!yCy+!%-Gl_1=D7}RTz>Pb1aj&yns13 znd1;sFxM-b6$>tjN=~UWVp@0*01loKk7JX-db{+F2y9`2je5vwlmkwqlyDmQGN&;p z9s*$6*z;g#&fSpI;1huI$NiyAP3Q?M@!o`egZZ2wft4*EtMz2L$KIKjVrK>YN%iN^Gk{Cisjp7okO03zDl! zlg4ys_77D(DmN?elwVyNj`787Iv<*DS;>rQ(r{|hRnX%u___{`{>N#G8dYndPql?l zwH2RgXT_cE`8lCOcG-){U67_$J_S?iW-0SsPb)RB z9<1B<@@e_-&cQ3~PlahG1lwZL4Xc%BU?cvZ@)^mrb#OmsiiK-(af%Ao0+IQ(5VLa$ zldMT8gN)}7^EY8elKq9O<$j-2kX@1a0BoOB^|!r~({4}i^}DD2X184}H)@S)C3i#F z0=J^q?{g{THrVVprU(#wl3@|MWFf9tOvJ6E{23R=> zMQu?07DJ7B*v-=}02@KvEzpL{yC3QOh#8@f8leR@LMw2D2F2leXoZ)%$;Y%G11GD?VZa1OvPVgoogle.cloud.beyondcorp.appconnectors.v1.AppConnector - */ -class AppConnector extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Unique resource name of the AppConnector. - * The name is ignored when creating a AppConnector. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. An arbitrary user-provided name for the AppConnector. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Output only. The current state of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Required. Principal information about the Identity of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo principal_info = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $principal_info = null; - /** - * Optional. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $resource_info = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Unique resource name of the AppConnector. - * The name is ignored when creating a AppConnector. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp when the resource was last modified. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Resource labels to represent user provided metadata. - * @type string $display_name - * Optional. An arbitrary user-provided name for the AppConnector. Cannot - * exceed 64 characters. - * @type string $uid - * Output only. A unique identifier for the instance generated by the - * system. - * @type int $state - * Output only. The current state of the AppConnector. - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo $principal_info - * Required. Principal information about the Identity of the AppConnector. - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resource_info - * Optional. Resource info of the connector. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Unique resource name of the AppConnector. - * The name is ignored when creating a AppConnector. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Unique resource name of the AppConnector. - * The name is ignored when creating a AppConnector. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Optional. An arbitrary user-provided name for the AppConnector. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. An arbitrary user-provided name for the AppConnector. Cannot - * exceed 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Output only. The current state of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. Principal information about the Identity of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo principal_info = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo|null - */ - public function getPrincipalInfo() - { - return $this->principal_info; - } - - public function hasPrincipalInfo() - { - return isset($this->principal_info); - } - - public function clearPrincipalInfo() - { - unset($this->principal_info); - } - - /** - * Required. Principal information about the Identity of the AppConnector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo principal_info = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo $var - * @return $this - */ - public function setPrincipalInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo::class); - $this->principal_info = $var; - - return $this; - } - - /** - * Optional. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo|null - */ - public function getResourceInfo() - { - return $this->resource_info; - } - - public function hasResourceInfo() - { - return isset($this->resource_info); - } - - public function clearResourceInfo() - { - unset($this->resource_info); - } - - /** - * Optional. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $var - * @return $this - */ - public function setResourceInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo::class); - $this->resource_info = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo.php deleted file mode 100644 index 00c58b75f4af..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo - */ -class PrincipalInfo extends \Google\Protobuf\Internal\Message -{ - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo\ServiceAccount $service_account - * A GCP service account. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * A GCP service account. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo.ServiceAccount service_account = 1; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo\ServiceAccount|null - */ - public function getServiceAccount() - { - return $this->readOneof(1); - } - - public function hasServiceAccount() - { - return $this->hasOneof(1); - } - - /** - * A GCP service account. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo.ServiceAccount service_account = 1; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo\ServiceAccount $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector\PrincipalInfo\ServiceAccount::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PrincipalInfo::class, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector_PrincipalInfo::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo/ServiceAccount.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo/ServiceAccount.php deleted file mode 100644 index 9219e3d17fe8..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/PrincipalInfo/ServiceAccount.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.AppConnector.PrincipalInfo.ServiceAccount - */ -class ServiceAccount extends \Google\Protobuf\Internal\Message -{ - /** - * Email address of the service account. - * - * Generated from protobuf field string email = 1; - */ - protected $email = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $email - * Email address of the service account. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Email address of the service account. - * - * Generated from protobuf field string email = 1; - * @return string - */ - public function getEmail() - { - return $this->email; - } - - /** - * Email address of the service account. - * - * Generated from protobuf field string email = 1; - * @param string $var - * @return $this - */ - public function setEmail($var) - { - GPBUtil::checkString($var, True); - $this->email = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ServiceAccount::class, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector_PrincipalInfo_ServiceAccount::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/State.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/State.php deleted file mode 100644 index 05d642b76b6d..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector/State.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.AppConnector.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * AppConnector is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * AppConnector has been created. - * - * Generated from protobuf enum CREATED = 2; - */ - const CREATED = 2; - /** - * AppConnector's configuration is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * AppConnector is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * AppConnector is down and may be restored in the future. - * This happens when CCFE sends ProjectState = OFF. - * - * Generated from protobuf enum DOWN = 5; - */ - const DOWN = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::CREATED => 'CREATED', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::DOWN => 'DOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector_State::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorInstanceConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorInstanceConfig.php deleted file mode 100644 index 59a44797fb90..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorInstanceConfig.php +++ /dev/null @@ -1,215 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.AppConnectorInstanceConfig - */ -class AppConnectorInstanceConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A monotonically increasing number generated and maintained - * by the API provider. Every time a config changes in the backend, the - * sequenceNumber should be bumped up to reflect the change. - * - * Generated from protobuf field int64 sequence_number = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $sequence_number = 0; - /** - * The SLM instance agent configuration. - * - * Generated from protobuf field .google.protobuf.Any instance_config = 2; - */ - protected $instance_config = null; - /** - * NotificationConfig defines the notification mechanism that the remote - * instance should subscribe to in order to receive notification. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.NotificationConfig notification_config = 3; - */ - protected $notification_config = null; - /** - * ImageConfig defines the GCR images to run for the remote agent's control - * plane. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ImageConfig image_config = 4; - */ - protected $image_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $sequence_number - * Required. A monotonically increasing number generated and maintained - * by the API provider. Every time a config changes in the backend, the - * sequenceNumber should be bumped up to reflect the change. - * @type \Google\Protobuf\Any $instance_config - * The SLM instance agent configuration. - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig $notification_config - * NotificationConfig defines the notification mechanism that the remote - * instance should subscribe to in order to receive notification. - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\ImageConfig $image_config - * ImageConfig defines the GCR images to run for the remote agent's control - * plane. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorInstanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. A monotonically increasing number generated and maintained - * by the API provider. Every time a config changes in the backend, the - * sequenceNumber should be bumped up to reflect the change. - * - * Generated from protobuf field int64 sequence_number = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return int|string - */ - public function getSequenceNumber() - { - return $this->sequence_number; - } - - /** - * Required. A monotonically increasing number generated and maintained - * by the API provider. Every time a config changes in the backend, the - * sequenceNumber should be bumped up to reflect the change. - * - * Generated from protobuf field int64 sequence_number = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int|string $var - * @return $this - */ - public function setSequenceNumber($var) - { - GPBUtil::checkInt64($var); - $this->sequence_number = $var; - - return $this; - } - - /** - * The SLM instance agent configuration. - * - * Generated from protobuf field .google.protobuf.Any instance_config = 2; - * @return \Google\Protobuf\Any|null - */ - public function getInstanceConfig() - { - return $this->instance_config; - } - - public function hasInstanceConfig() - { - return isset($this->instance_config); - } - - public function clearInstanceConfig() - { - unset($this->instance_config); - } - - /** - * The SLM instance agent configuration. - * - * Generated from protobuf field .google.protobuf.Any instance_config = 2; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setInstanceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->instance_config = $var; - - return $this; - } - - /** - * NotificationConfig defines the notification mechanism that the remote - * instance should subscribe to in order to receive notification. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.NotificationConfig notification_config = 3; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * NotificationConfig defines the notification mechanism that the remote - * instance should subscribe to in order to receive notification. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.NotificationConfig notification_config = 3; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - - /** - * ImageConfig defines the GCR images to run for the remote agent's control - * plane. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ImageConfig image_config = 4; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ImageConfig|null - */ - public function getImageConfig() - { - return $this->image_config; - } - - public function hasImageConfig() - { - return isset($this->image_config); - } - - public function clearImageConfig() - { - unset($this->image_config); - } - - /** - * ImageConfig defines the GCR images to run for the remote agent's control - * plane. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ImageConfig image_config = 4; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ImageConfig $var - * @return $this - */ - public function setImageConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\ImageConfig::class); - $this->image_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorOperationMetadata.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorOperationMetadata.php deleted file mode 100644 index 28e101a224c3..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnectorOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.AppConnectorOperationMetadata - */ -class AppConnectorOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_PrincipalInfo.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_PrincipalInfo.php deleted file mode 100644 index c4ae2a7ddf6c..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/AppConnector_PrincipalInfo.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/ListAppConnectors', - $argument, - ['\Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single AppConnector. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\GetAppConnectorRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetAppConnector(\Google\Cloud\BeyondCorp\AppConnectors\V1\GetAppConnectorRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/GetAppConnector', - $argument, - ['\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', 'decode'], - $metadata, $options); - } - - /** - * Creates a new AppConnector in a given project and location. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\CreateAppConnectorRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateAppConnector(\Google\Cloud\BeyondCorp\AppConnectors\V1\CreateAppConnectorRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/CreateAppConnector', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates the parameters of a single AppConnector. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\UpdateAppConnectorRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateAppConnector(\Google\Cloud\BeyondCorp\AppConnectors\V1\UpdateAppConnectorRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/UpdateAppConnector', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single AppConnector. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\DeleteAppConnectorRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteAppConnector(\Google\Cloud\BeyondCorp\AppConnectors\V1\DeleteAppConnectorRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/DeleteAppConnector', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Report status for a given connector. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ReportStatusRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ReportStatus(\Google\Cloud\BeyondCorp\AppConnectors\V1\ReportStatusRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/ReportStatus', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/CreateAppConnectorRequest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/CreateAppConnectorRequest.php deleted file mode 100644 index 971d96884ddc..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/CreateAppConnectorRequest.php +++ /dev/null @@ -1,296 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.CreateAppConnectorRequest - */ -class CreateAppConnectorRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. User-settable AppConnector resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $app_connector_id = ''; - /** - * Required. A BeyondCorp AppConnector resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $app_connector = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * Please see {@see AppConnectorsServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector Required. A BeyondCorp AppConnector resource. - * @param string $appConnectorId Optional. User-settable AppConnector resource ID. - * - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\CreateAppConnectorRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector, string $appConnectorId): self - { - return (new self()) - ->setParent($parent) - ->setAppConnector($appConnector) - ->setAppConnectorId($appConnectorId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * @type string $app_connector_id - * Optional. User-settable AppConnector resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $app_connector - * Required. A BeyondCorp AppConnector resource. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. User-settable AppConnector resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getAppConnectorId() - { - return $this->app_connector_id; - } - - /** - * Optional. User-settable AppConnector resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_connector_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setAppConnectorId($var) - { - GPBUtil::checkString($var, True); - $this->app_connector_id = $var; - - return $this; - } - - /** - * Required. A BeyondCorp AppConnector resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector|null - */ - public function getAppConnector() - { - return $this->app_connector; - } - - public function hasAppConnector() - { - return isset($this->app_connector); - } - - public function clearAppConnector() - { - unset($this->app_connector); - } - - /** - * Required. A BeyondCorp AppConnector resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $var - * @return $this - */ - public function setAppConnector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector::class); - $this->app_connector = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/DeleteAppConnectorRequest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/DeleteAppConnectorRequest.php deleted file mode 100644 index a9ac702ffd42..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/DeleteAppConnectorRequest.php +++ /dev/null @@ -1,198 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.DeleteAppConnectorRequest - */ -class DeleteAppConnectorRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $name Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\DeleteAppConnectorRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/GetAppConnectorRequest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/GetAppConnectorRequest.php deleted file mode 100644 index 977e4560e303..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/GetAppConnectorRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.GetAppConnectorRequest - */ -class GetAppConnectorRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\GetAppConnectorRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/HealthStatus.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/HealthStatus.php deleted file mode 100644 index 4c2c7b1895f9..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/HealthStatus.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.HealthStatus - */ -class HealthStatus -{ - /** - * Health status is unknown: not initialized or failed to retrieve. - * - * Generated from protobuf enum HEALTH_STATUS_UNSPECIFIED = 0; - */ - const HEALTH_STATUS_UNSPECIFIED = 0; - /** - * The resource is healthy. - * - * Generated from protobuf enum HEALTHY = 1; - */ - const HEALTHY = 1; - /** - * The resource is unhealthy. - * - * Generated from protobuf enum UNHEALTHY = 2; - */ - const UNHEALTHY = 2; - /** - * The resource is unresponsive. - * - * Generated from protobuf enum UNRESPONSIVE = 3; - */ - const UNRESPONSIVE = 3; - /** - * Some sub-resources are UNHEALTHY. - * - * Generated from protobuf enum DEGRADED = 4; - */ - const DEGRADED = 4; - - private static $valueToName = [ - self::HEALTH_STATUS_UNSPECIFIED => 'HEALTH_STATUS_UNSPECIFIED', - self::HEALTHY => 'HEALTHY', - self::UNHEALTHY => 'UNHEALTHY', - self::UNRESPONSIVE => 'UNRESPONSIVE', - self::DEGRADED => 'DEGRADED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ImageConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ImageConfig.php deleted file mode 100644 index f31d9006cf66..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ImageConfig.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.ImageConfig - */ -class ImageConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The initial image the remote agent will attempt to run for the control - * plane. - * - * Generated from protobuf field string target_image = 1; - */ - protected $target_image = ''; - /** - * The stable image that the remote agent will fallback to if the target image - * fails. - * - * Generated from protobuf field string stable_image = 2; - */ - protected $stable_image = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $target_image - * The initial image the remote agent will attempt to run for the control - * plane. - * @type string $stable_image - * The stable image that the remote agent will fallback to if the target image - * fails. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorInstanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * The initial image the remote agent will attempt to run for the control - * plane. - * - * Generated from protobuf field string target_image = 1; - * @return string - */ - public function getTargetImage() - { - return $this->target_image; - } - - /** - * The initial image the remote agent will attempt to run for the control - * plane. - * - * Generated from protobuf field string target_image = 1; - * @param string $var - * @return $this - */ - public function setTargetImage($var) - { - GPBUtil::checkString($var, True); - $this->target_image = $var; - - return $this; - } - - /** - * The stable image that the remote agent will fallback to if the target image - * fails. - * - * Generated from protobuf field string stable_image = 2; - * @return string - */ - public function getStableImage() - { - return $this->stable_image; - } - - /** - * The stable image that the remote agent will fallback to if the target image - * fails. - * - * Generated from protobuf field string stable_image = 2; - * @param string $var - * @return $this - */ - public function setStableImage($var) - { - GPBUtil::checkString($var, True); - $this->stable_image = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsRequest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsRequest.php deleted file mode 100644 index eb6639769249..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsRequest.php +++ /dev/null @@ -1,258 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.ListAppConnectorsRequest - */ -class ListAppConnectorsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectorsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectorsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * Please see {@see AppConnectorsServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * @type int $page_size - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectorsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * @type string $page_token - * Optional. The next_page_token value returned from a previous - * ListAppConnectorsRequest, if any. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $order_by - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectorsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppConnectorsResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectorsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppConnectorsRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsResponse.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsResponse.php deleted file mode 100644 index 4dd5d6387e1b..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ListAppConnectorsResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.ListAppConnectorsResponse - */ -class ListAppConnectorsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of BeyondCorp AppConnectors in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connectors = 1; - */ - private $app_connectors; - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector>|\Google\Protobuf\Internal\RepeatedField $app_connectors - * A list of BeyondCorp AppConnectors in the project. - * @type string $next_page_token - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * A list of locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * A list of BeyondCorp AppConnectors in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connectors = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAppConnectors() - { - return $this->app_connectors; - } - - /** - * A list of BeyondCorp AppConnectors in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connectors = 1; - * @param array<\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAppConnectors($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector::class); - $this->app_connectors = $arr; - - return $this; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig.php deleted file mode 100644 index 0ab5679cdf95..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.NotificationConfig - */ -class NotificationConfig extends \Google\Protobuf\Internal\Message -{ - protected $config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig\CloudPubSubNotificationConfig $pubsub_notification - * Cloud Pub/Sub Configuration to receive notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorInstanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Cloud Pub/Sub Configuration to receive notifications. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.NotificationConfig.CloudPubSubNotificationConfig pubsub_notification = 1; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig\CloudPubSubNotificationConfig|null - */ - public function getPubsubNotification() - { - return $this->readOneof(1); - } - - public function hasPubsubNotification() - { - return $this->hasOneof(1); - } - - /** - * Cloud Pub/Sub Configuration to receive notifications. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.NotificationConfig.CloudPubSubNotificationConfig pubsub_notification = 1; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig\CloudPubSubNotificationConfig $var - * @return $this - */ - public function setPubsubNotification($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig\CloudPubSubNotificationConfig::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getConfig() - { - return $this->whichOneof("config"); - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig/CloudPubSubNotificationConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig/CloudPubSubNotificationConfig.php deleted file mode 100644 index b4a622dabefe..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig/CloudPubSubNotificationConfig.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.NotificationConfig.CloudPubSubNotificationConfig - */ -class CloudPubSubNotificationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The Pub/Sub subscription the AppConnector uses to receive notifications. - * - * Generated from protobuf field string pubsub_subscription = 1; - */ - protected $pubsub_subscription = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $pubsub_subscription - * The Pub/Sub subscription the AppConnector uses to receive notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorInstanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * The Pub/Sub subscription the AppConnector uses to receive notifications. - * - * Generated from protobuf field string pubsub_subscription = 1; - * @return string - */ - public function getPubsubSubscription() - { - return $this->pubsub_subscription; - } - - /** - * The Pub/Sub subscription the AppConnector uses to receive notifications. - * - * Generated from protobuf field string pubsub_subscription = 1; - * @param string $var - * @return $this - */ - public function setPubsubSubscription($var) - { - GPBUtil::checkString($var, True); - $this->pubsub_subscription = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CloudPubSubNotificationConfig::class, \Google\Cloud\BeyondCorp\AppConnectors\V1\NotificationConfig_CloudPubSubNotificationConfig::class); - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig_CloudPubSubNotificationConfig.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig_CloudPubSubNotificationConfig.php deleted file mode 100644 index f8c4b58c7b3c..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/NotificationConfig_CloudPubSubNotificationConfig.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.ReportStatusRequest - */ -class ReportStatusRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * - * Generated from protobuf field string app_connector = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $app_connector = ''; - /** - * Required. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource_info = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $appConnector Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * Please see {@see AppConnectorsServiceClient::appConnectorName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resourceInfo Required. Resource info of the connector. - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ReportStatusRequest - * - * @experimental - */ - public static function build(string $appConnector, \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resourceInfo): self - { - return (new self()) - ->setAppConnector($appConnector) - ->setResourceInfo($resourceInfo); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $app_connector - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $resource_info - * Required. Resource info of the connector. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * - * Generated from protobuf field string app_connector = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getAppConnector() - { - return $this->app_connector; - } - - /** - * Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * - * Generated from protobuf field string app_connector = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setAppConnector($var) - { - GPBUtil::checkString($var, True); - $this->app_connector = $var; - - return $this; - } - - /** - * Required. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo|null - */ - public function getResourceInfo() - { - return $this->resource_info; - } - - public function hasResourceInfo() - { - return isset($this->resource_info); - } - - public function clearResourceInfo() - { - unset($this->resource_info); - } - - /** - * Required. Resource info of the connector. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo resource_info = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo $var - * @return $this - */ - public function setResourceInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo::class); - $this->resource_info = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ResourceInfo.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ResourceInfo.php deleted file mode 100644 index e2ea6c977df7..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/ResourceInfo.php +++ /dev/null @@ -1,240 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.ResourceInfo - */ -class ResourceInfo extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Unique Id for the resource. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $id = ''; - /** - * Overall health status. Overall status is derived based on the status of - * each sub level resources. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.HealthStatus status = 2; - */ - protected $status = 0; - /** - * Specific details for the resource. This is for internal use only. - * - * Generated from protobuf field .google.protobuf.Any resource = 3; - */ - protected $resource = null; - /** - * The timestamp to collect the info. It is suggested to be set by - * the topmost level resource only. - * - * Generated from protobuf field .google.protobuf.Timestamp time = 4; - */ - protected $time = null; - /** - * List of Info for the sub level resources. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo sub = 5; - */ - private $sub; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * Required. Unique Id for the resource. - * @type int $status - * Overall health status. Overall status is derived based on the status of - * each sub level resources. - * @type \Google\Protobuf\Any $resource - * Specific details for the resource. This is for internal use only. - * @type \Google\Protobuf\Timestamp $time - * The timestamp to collect the info. It is suggested to be set by - * the topmost level resource only. - * @type array<\Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo>|\Google\Protobuf\Internal\RepeatedField $sub - * List of Info for the sub level resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\ResourceInfo::initOnce(); - parent::__construct($data); - } - - /** - * Required. Unique Id for the resource. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Required. Unique Id for the resource. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Overall health status. Overall status is derived based on the status of - * each sub level resources. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.HealthStatus status = 2; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * Overall health status. Overall status is derived based on the status of - * each sub level resources. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.HealthStatus status = 2; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\HealthStatus::class); - $this->status = $var; - - return $this; - } - - /** - * Specific details for the resource. This is for internal use only. - * - * Generated from protobuf field .google.protobuf.Any resource = 3; - * @return \Google\Protobuf\Any|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * Specific details for the resource. This is for internal use only. - * - * Generated from protobuf field .google.protobuf.Any resource = 3; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->resource = $var; - - return $this; - } - - /** - * The timestamp to collect the info. It is suggested to be set by - * the topmost level resource only. - * - * Generated from protobuf field .google.protobuf.Timestamp time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getTime() - { - return $this->time; - } - - public function hasTime() - { - return isset($this->time); - } - - public function clearTime() - { - unset($this->time); - } - - /** - * The timestamp to collect the info. It is suggested to be set by - * the topmost level resource only. - * - * Generated from protobuf field .google.protobuf.Timestamp time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->time = $var; - - return $this; - } - - /** - * List of Info for the sub level resources. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo sub = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSub() - { - return $this->sub; - } - - /** - * List of Info for the sub level resources. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appconnectors.v1.ResourceInfo sub = 5; - * @param array<\Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSub($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppConnectors\V1\ResourceInfo::class); - $this->sub = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/UpdateAppConnectorRequest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/UpdateAppConnectorRequest.php deleted file mode 100644 index eb3293b86e4f..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/proto/src/Google/Cloud/BeyondCorp/AppConnectors/V1/UpdateAppConnectorRequest.php +++ /dev/null @@ -1,273 +0,0 @@ -google.cloud.beyondcorp.appconnectors.v1.UpdateAppConnectorRequest - */ -class UpdateAppConnectorRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $app_connector = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * @param \Google\Protobuf\FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\UpdateAppConnectorRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $appConnector, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setAppConnector($appConnector) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * @type \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $app_connector - * Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appconnectors\V1\AppConnectorsService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector|null - */ - public function getAppConnector() - { - return $this->app_connector; - } - - public function hasAppConnector() - { - return isset($this->app_connector); - } - - public function clearAppConnector() - { - unset($this->app_connector); - } - - /** - * Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.appconnectors.v1.AppConnector app_connector = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector $var - * @return $this - */ - public function setAppConnector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector::class); - $this->app_connector = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/create_app_connector.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/create_app_connector.php deleted file mode 100644 index 1b05cc9908eb..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/create_app_connector.php +++ /dev/null @@ -1,93 +0,0 @@ -setName($appConnectorName) - ->setPrincipalInfo($appConnectorPrincipalInfo); - $request = (new CreateAppConnectorRequest()) - ->setParent($formattedParent) - ->setAppConnector($appConnector); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->createAppConnector($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppConnector $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 = AppConnectorsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $appConnectorName = '[NAME]'; - - create_app_connector_sample($formattedParent, $appConnectorName); -} -// [END beyondcorp_v1_generated_AppConnectorsService_CreateAppConnector_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/delete_app_connector.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/delete_app_connector.php deleted file mode 100644 index af1ea82eaa2a..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/delete_app_connector.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->deleteAppConnector($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 = AppConnectorsServiceClient::appConnectorName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTOR]' - ); - - delete_app_connector_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppConnectorsService_DeleteAppConnector_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_app_connector.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_app_connector.php deleted file mode 100644 index 6f5f1f2de12d..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_app_connector.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var AppConnector $response */ - $response = $appConnectorsServiceClient->getAppConnector($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 = AppConnectorsServiceClient::appConnectorName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTOR]' - ); - - get_app_connector_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppConnectorsService_GetAppConnector_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_iam_policy.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_iam_policy.php deleted file mode 100644 index e58f877cbf19..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appConnectorsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectorsService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_location.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_location.php deleted file mode 100644 index 159cc30239e7..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppConnectorsService_GetLocation_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_app_connectors.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_app_connectors.php deleted file mode 100644 index cbad9ee97e50..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_app_connectors.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $appConnectorsServiceClient->listAppConnectors($request); - - /** @var AppConnector $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 = AppConnectorsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_app_connectors_sample($formattedParent); -} -// [END beyondcorp_v1_generated_AppConnectorsService_ListAppConnectors_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_locations.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_locations.php deleted file mode 100644 index 67ebc9f4fa20..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppConnectorsService_ListLocations_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/report_status.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/report_status.php deleted file mode 100644 index e1ffe18726bd..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/report_status.php +++ /dev/null @@ -1,94 +0,0 @@ -setId($resourceInfoId); - $request = (new ReportStatusRequest()) - ->setAppConnector($formattedAppConnector) - ->setResourceInfo($resourceInfo); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->reportStatus($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppConnector $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 -{ - $formattedAppConnector = AppConnectorsServiceClient::appConnectorName( - '[PROJECT]', - '[LOCATION]', - '[APP_CONNECTOR]' - ); - $resourceInfoId = '[ID]'; - - report_status_sample($formattedAppConnector, $resourceInfoId); -} -// [END beyondcorp_v1_generated_AppConnectorsService_ReportStatus_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/set_iam_policy.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/set_iam_policy.php deleted file mode 100644 index 3f271dfc38b6..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appConnectorsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectorsService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php deleted file mode 100644 index d84db57709f1..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $appConnectorsServiceClient->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); -} -// [END beyondcorp_v1_generated_AppConnectorsService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/update_app_connector.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/update_app_connector.php deleted file mode 100644 index 31156eca9fe1..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/samples/V1/AppConnectorsServiceClient/update_app_connector.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($appConnectorName) - ->setPrincipalInfo($appConnectorPrincipalInfo); - $request = (new UpdateAppConnectorRequest()) - ->setUpdateMask($updateMask) - ->setAppConnector($appConnector); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appConnectorsServiceClient->updateAppConnector($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppConnector $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 -{ - $appConnectorName = '[NAME]'; - - update_app_connector_sample($appConnectorName); -} -// [END beyondcorp_v1_generated_AppConnectorsService_UpdateAppConnector_sync] diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/AppConnectorsServiceClient.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/AppConnectorsServiceClient.php deleted file mode 100644 index 77dee06f5580..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/AppConnectorsServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $appConnector = new AppConnector(); - * $operationResponse = $appConnectorsServiceClient->createAppConnector($formattedParent, $appConnector); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectorsServiceClient->createAppConnector($formattedParent, $appConnector); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectorsServiceClient->resumeOperation($operationName, 'createAppConnector'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * 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. - */ -class AppConnectorsServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'beyondcorp.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $appConnectorNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/app_connectors_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/app_connectors_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/app_connectors_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/app_connectors_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getAppConnectorNameTemplate() - { - if (self::$appConnectorNameTemplate == null) { - self::$appConnectorNameTemplate = new PathTemplate('projects/{project}/locations/{location}/appConnectors/{app_connector}'); - } - - return self::$appConnectorNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'appConnector' => self::getAppConnectorNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * app_connector resource. - * - * @param string $project - * @param string $location - * @param string $appConnector - * - * @return string The formatted app_connector resource. - */ - public static function appConnectorName($project, $location, $appConnector) - { - return self::getAppConnectorNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'app_connector' => $appConnector, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - appConnector: projects/{project}/locations/{location}/appConnectors/{app_connector} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'beyondcorp.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new AppConnector in a given project and location. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $formattedParent = $appConnectorsServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $appConnector = new AppConnector(); - * $operationResponse = $appConnectorsServiceClient->createAppConnector($formattedParent, $appConnector); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectorsServiceClient->createAppConnector($formattedParent, $appConnector); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectorsServiceClient->resumeOperation($operationName, 'createAppConnector'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource project name of the AppConnector location using the - * form: `projects/{project_id}/locations/{location_id}` - * @param AppConnector $appConnector Required. A BeyondCorp AppConnector resource. - * @param array $optionalArgs { - * Optional. - * - * @type string $appConnectorId - * Optional. User-settable AppConnector resource ID. - * - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createAppConnector($parent, $appConnector, array $optionalArgs = []) - { - $request = new CreateAppConnectorRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAppConnector($appConnector); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['appConnectorId'])) { - $request->setAppConnectorId($optionalArgs['appConnectorId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateAppConnector', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single AppConnector. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $formattedName = $appConnectorsServiceClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - * $operationResponse = $appConnectorsServiceClient->deleteAppConnector($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectorsServiceClient->deleteAppConnector($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectorsServiceClient->resumeOperation($operationName, 'deleteAppConnector'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteAppConnector($name, array $optionalArgs = []) - { - $request = new DeleteAppConnectorRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteAppConnector', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single AppConnector. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $formattedName = $appConnectorsServiceClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - * $response = $appConnectorsServiceClient->getAppConnector($formattedName); - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp AppConnector name using the form: - * `projects/{project_id}/locations/{location_id}/appConnectors/{app_connector_id}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector - * - * @throws ApiException if the remote call fails - */ - public function getAppConnector($name, array $optionalArgs = []) - { - $request = new GetAppConnectorRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetAppConnector', AppConnector::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists AppConnectors in a given project and location. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $formattedParent = $appConnectorsServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $appConnectorsServiceClient->listAppConnectors($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appConnectorsServiceClient->listAppConnectors($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource name of the AppConnector location using the form: - * `projects/{project_id}/locations/{location_id}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $orderBy - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listAppConnectors($parent, array $optionalArgs = []) - { - $request = new ListAppConnectorsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAppConnectors', $optionalArgs, ListAppConnectorsResponse::class, $request); - } - - /** - * Report status for a given connector. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $formattedAppConnector = $appConnectorsServiceClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - * $resourceInfo = new ResourceInfo(); - * $operationResponse = $appConnectorsServiceClient->reportStatus($formattedAppConnector, $resourceInfo); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectorsServiceClient->reportStatus($formattedAppConnector, $resourceInfo); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectorsServiceClient->resumeOperation($operationName, 'reportStatus'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $appConnector Required. BeyondCorp Connector name using the form: - * `projects/{project_id}/locations/{location_id}/connectors/{connector}` - * @param ResourceInfo $resourceInfo Required. Resource info of the connector. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function reportStatus($appConnector, $resourceInfo, array $optionalArgs = []) - { - $request = new ReportStatusRequest(); - $requestParamHeaders = []; - $request->setAppConnector($appConnector); - $request->setResourceInfo($resourceInfo); - $requestParamHeaders['app_connector'] = $appConnector; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('ReportStatus', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the parameters of a single AppConnector. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $appConnector = new AppConnector(); - * $operationResponse = $appConnectorsServiceClient->updateAppConnector($updateMask, $appConnector); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appConnectorsServiceClient->updateAppConnector($updateMask, $appConnector); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appConnectorsServiceClient->resumeOperation($operationName, 'updateAppConnector'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Mask of fields to update. At least one path must be supplied in - * this field. The elements of the repeated paths field may only include these - * fields from [BeyondCorp.AppConnector]: - * * `labels` - * * `display_name` - * @param AppConnector $appConnector Required. AppConnector message with updated fields. Only supported fields - * specified in update_mask are updated. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateAppConnector($updateMask, $appConnector, array $optionalArgs = []) - { - $request = new UpdateAppConnectorRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setAppConnector($appConnector); - $requestParamHeaders['app_connector.name'] = $appConnector->getName(); - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateAppConnector', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $response = $appConnectorsServiceClient->getLocation(); - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $appConnectorsServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appConnectorsServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $resource = 'resource'; - * $response = $appConnectorsServiceClient->getIamPolicy($resource); - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $appConnectorsServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $appConnectorsServiceClient = new AppConnectorsServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $appConnectorsServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $appConnectorsServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 45b46c7018ad..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,73 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.beyondcorp.appconnectors.v1", - "libraryPackage": "Google\\Cloud\\BeyondCorp\\AppConnectors\\V1", - "services": { - "AppConnectorsService": { - "clients": { - "grpc": { - "libraryClient": "AppConnectorsServiceGapicClient", - "rpcs": { - "CreateAppConnector": { - "methods": [ - "createAppConnector" - ] - }, - "DeleteAppConnector": { - "methods": [ - "deleteAppConnector" - ] - }, - "GetAppConnector": { - "methods": [ - "getAppConnector" - ] - }, - "ListAppConnectors": { - "methods": [ - "listAppConnectors" - ] - }, - "ReportStatus": { - "methods": [ - "reportStatus" - ] - }, - "UpdateAppConnector": { - "methods": [ - "updateAppConnector" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_client_config.json b/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_client_config.json deleted file mode 100644 index 6a2292abae69..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_client_config.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "interfaces": { - "google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService": { - "retry_codes": { - "no_retry_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - } - }, - "methods": { - "CreateAppConnector": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteAppConnector": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetAppConnector": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListAppConnectors": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ReportStatus": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "UpdateAppConnector": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_descriptor_config.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_descriptor_config.php deleted file mode 100644 index 2f6d0ac9a2c9..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_descriptor_config.php +++ /dev/null @@ -1,194 +0,0 @@ - [ - 'google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService' => [ - 'CreateAppConnector' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppConnector' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ReportStatus' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'app_connector', - 'fieldAccessors' => [ - 'getAppConnector', - ], - ], - ], - ], - 'UpdateAppConnector' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnectorOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'app_connector.name', - 'fieldAccessors' => [ - 'getAppConnector', - 'getName', - ], - ], - ], - ], - 'GetAppConnector' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppConnectors\V1\AppConnector', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAppConnectors' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAppConnectors', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppConnectors\V1\ListAppConnectorsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'appConnector' => 'projects/{project}/locations/{location}/appConnectors/{app_connector}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_rest_client_config.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_rest_client_config.php deleted file mode 100644 index e2c275550503..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/src/V1/resources/app_connectors_service_rest_client_config.php +++ /dev/null @@ -1,252 +0,0 @@ - [ - 'google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService' => [ - 'CreateAppConnector' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appConnectors', - 'body' => 'app_connector', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppConnector' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appConnectors/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetAppConnector' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appConnectors/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAppConnectors' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appConnectors', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ReportStatus' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{app_connector=projects/*/locations/*/appConnectors/*}:reportStatus', - 'body' => '*', - 'placeholders' => [ - 'app_connector' => [ - 'getters' => [ - 'getAppConnector', - ], - ], - ], - ], - 'UpdateAppConnector' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{app_connector.name=projects/*/locations/*/appConnectors/*}', - 'body' => 'app_connector', - 'placeholders' => [ - 'app_connector.name' => [ - 'getters' => [ - 'getAppConnector', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/AppConnectorsServiceClientTest.php b/owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/AppConnectorsServiceClientTest.php deleted file mode 100644 index ed065cbf52c7..000000000000 --- a/owl-bot-staging/BeyondCorpAppConnectors/v1/tests/Unit/V1/AppConnectorsServiceClientTest.php +++ /dev/null @@ -1,1034 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AppConnectorsServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AppConnectorsServiceClient($options); - } - - /** @test */ - public function createAppConnectorTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnector(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAppConnectorTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appConnector = new AppConnector(); - $appConnectorName = 'appConnectorName-1263736873'; - $appConnector->setName($appConnectorName); - $appConnectorPrincipalInfo = new PrincipalInfo(); - $appConnector->setPrincipalInfo($appConnectorPrincipalInfo); - $response = $gapicClient->createAppConnector($formattedParent, $appConnector); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/CreateAppConnector', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAppConnector(); - $this->assertProtobufEquals($appConnector, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppConnectorTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAppConnectorExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appConnector = new AppConnector(); - $appConnectorName = 'appConnectorName-1263736873'; - $appConnector->setName($appConnectorName); - $appConnectorPrincipalInfo = new PrincipalInfo(); - $appConnector->setPrincipalInfo($appConnectorPrincipalInfo); - $response = $gapicClient->createAppConnector($formattedParent, $appConnector); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppConnectorTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppConnectorTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteAppConnectorTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $response = $gapicClient->deleteAppConnector($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/DeleteAppConnector', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppConnectorTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppConnectorExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $response = $gapicClient->deleteAppConnector($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppConnectorTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAppConnectorTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnector(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $response = $gapicClient->getAppConnector($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/GetAppConnector', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAppConnectorExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - try { - $gapicClient->getAppConnector($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppConnectorsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $appConnectorsElement = new AppConnector(); - $appConnectors = [ - $appConnectorsElement, - ]; - $expectedResponse = new ListAppConnectorsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAppConnectors($appConnectors); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listAppConnectors($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAppConnectors()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/ListAppConnectors', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppConnectorsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listAppConnectors($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function reportStatusTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/reportStatusTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnector(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/reportStatusTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedAppConnector = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $resourceInfo = new ResourceInfo(); - $resourceInfoId = 'resourceInfoId-332404713'; - $resourceInfo->setId($resourceInfoId); - $response = $gapicClient->reportStatus($formattedAppConnector, $resourceInfo); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/ReportStatus', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getAppConnector(); - $this->assertProtobufEquals($formattedAppConnector, $actualValue); - $actualValue = $actualApiRequestObject->getResourceInfo(); - $this->assertProtobufEquals($resourceInfo, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/reportStatusTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function reportStatusExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/reportStatusTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedAppConnector = $gapicClient->appConnectorName('[PROJECT]', '[LOCATION]', '[APP_CONNECTOR]'); - $resourceInfo = new ResourceInfo(); - $resourceInfoId = 'resourceInfoId-332404713'; - $resourceInfo->setId($resourceInfoId); - $response = $gapicClient->reportStatus($formattedAppConnector, $resourceInfo); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/reportStatusTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateAppConnectorTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $expectedResponse = new AppConnector(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateAppConnectorTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $appConnector = new AppConnector(); - $appConnectorName = 'appConnectorName-1263736873'; - $appConnector->setName($appConnectorName); - $appConnectorPrincipalInfo = new PrincipalInfo(); - $appConnector->setPrincipalInfo($appConnectorPrincipalInfo); - $response = $gapicClient->updateAppConnector($updateMask, $appConnector); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appconnectors.v1.AppConnectorsService/UpdateAppConnector', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getAppConnector(); - $this->assertProtobufEquals($appConnector, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateAppConnectorTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateAppConnectorExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateAppConnectorTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $appConnector = new AppConnector(); - $appConnectorName = 'appConnectorName-1263736873'; - $appConnector->setName($appConnectorName); - $appConnectorPrincipalInfo = new PrincipalInfo(); - $appConnector->setPrincipalInfo($appConnectorPrincipalInfo); - $response = $gapicClient->updateAppConnector($updateMask, $appConnector); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateAppConnectorTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appgateways/V1/AppGatewaysService.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Appgateways/V1/AppGatewaysService.php deleted file mode 100644 index 1fa4c63d4db5f5d5850de57f222d653a77f6c861..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4655 zcmbtY&2JM&6tC@k*kdSWA;dAQx)=l@g|(6*6>Ui9#&%396I+R)rLweIugA{9W_P>0 zPU=Rv^j2bg<2<=C-Bj*cN!cRO8oc4Zd7jYg_?Q$L!fE z7WuAec6D4(b+gwlv~b@v+Nx<=1;w(upm|s6JB6Kj@+kYyvV-j%O~nGWhLE9bW5-fd z%vb6w53#GX6<29isN!akC~mFaI&2liE_MUJ$(z}mo>`(!>+rM8M^QZFp z^EP&Swy{Y4CJOe0U(F+6lq{_&8HPzvFbzi(!ceqA&vT7P#yJr}h(QVc&a->fdWWZfRgQMsw+t$$@Q_gQMYaYW=yB!d^3TZMM zP(TQ|f&TjlN$;H>+;yfxpeZJVDJDcxOxT&vO?##kOM`SIjIjjEeG*yd5L)Dx$BVaN zCbGfy!1tD}dP{nUaKQ`^9x_1l8B(C&`Y^H$`Cnq_QdM)@NRn>gZ+ieWcMnZiiVeV%dRY&c;E(_)6ln6yv55qVHYv z88)&Bs+lfaKocEJhXl=zg)gU2(zM&ymRtSocz!zmeSHO1d*6cU)}|b#7)Mo_`za z5pr|r><$!rxKprf8aiV*NnOZ4hsaA<$45o}9*7P(L+NBOA998qP0yK^NrXZIxbp*y z(irccv`TrBNrF)<(+fHO%=y_T1VxP4OmHC8vuOBKidY;$Y7U!kwT1vq`G#?kSXQ5_yIw@zvI{snFM_XiCv_Q-v*USv3s<)6T)kA`0H> zDeOtUzG9$`S>HsdEz@yj3Qn5Fvv>;q4?sr%P;M1nIKm)z5lvc-DwAkgd8TLrjd0V# zP2tFvX}e+JjpuHobcA&-jS|mrpUHA((Kuvcj~(2U7{43Ke~QM44`3(Lcv3IRkJdNq z<>K1vTDg?@00dHvVqLCp)V_X_iREQ9PD$XV(D}`V)EM4=1|^FdWvQ{YUdhD3^dx-( zO>qvE9@R^1DM6k}9@4cG_WYmwq-*w@+QMF>SnlVa$I<1m zSOh(f-#wG0kCqBT-UvxQkCNDEpQyUPh3YCcw6@_bn;^Ao2ivW%3@13a3P=X_92q(+ z2kz|frcH2H(Iu~Vlk`!b)z)>|!_j&`>tlk;lKVoFL9qik(Xv2qlElK_lL#;kpz`{E z?vEHcH*|kzyJAje4ZnG<_7qG zC3$@k_iGHD9q0kLd!srvAm)d3il!yMJP-w`<;TP@aD?afUrDr0;eL#x%y7%Wjg0NE zq#w!0J`Ry?RS0q;{~|`cUe2EsdokLmyppak)^0@-GWr|(j|1uEz+L{4m_i7eyG0M7kqKcszgLZ)|#V4sXywwl>M6 z!>|5L7>Qd~1Tz^4X2xlk^swAw)(Fq#kSP5#t8BlZ^%T I(LO@|1CA;ShX4Qo diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway.php deleted file mode 100644 index 37dbc13aa53e..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway.php +++ /dev/null @@ -1,442 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGateway - */ -class AppGateway extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Unique resource name of the AppGateway. - * The name is ignored when creating an AppGateway. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. An arbitrary user-provided name for the AppGateway. Cannot exceed - * 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Required. The type of network connectivity used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Output only. The current state of the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uri = ''; - /** - * Output only. A list of connections allocated for the Gateway - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway.AllocatedConnection allocated_connections = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $allocated_connections; - /** - * Required. The type of hosting used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.HostType host_type = 11 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $host_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Unique resource name of the AppGateway. - * The name is ignored when creating an AppGateway. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp when the resource was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp when the resource was last modified. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Resource labels to represent user provided metadata. - * @type string $display_name - * Optional. An arbitrary user-provided name for the AppGateway. Cannot exceed - * 64 characters. - * @type string $uid - * Output only. A unique identifier for the instance generated by the - * system. - * @type int $type - * Required. The type of network connectivity used by the AppGateway. - * @type int $state - * Output only. The current state of the AppGateway. - * @type string $uri - * Output only. Server-defined URI for this resource. - * @type array<\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\AllocatedConnection>|\Google\Protobuf\Internal\RepeatedField $allocated_connections - * Output only. A list of connections allocated for the Gateway - * @type int $host_type - * Required. The type of hosting used by the AppGateway. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Unique resource name of the AppGateway. - * The name is ignored when creating an AppGateway. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Unique resource name of the AppGateway. - * The name is ignored when creating an AppGateway. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Timestamp when the resource was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Timestamp when the resource was last modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Resource labels to represent user provided metadata. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Optional. An arbitrary user-provided name for the AppGateway. Cannot exceed - * 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. An arbitrary user-provided name for the AppGateway. Cannot exceed - * 64 characters. - * - * Generated from protobuf field string display_name = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. A unique identifier for the instance generated by the - * system. - * - * Generated from protobuf field string uid = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Required. The type of network connectivity used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of network connectivity used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.Type type = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. The current state of the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Output only. Server-defined URI for this resource. - * - * Generated from protobuf field string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Output only. A list of connections allocated for the Gateway - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway.AllocatedConnection allocated_connections = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllocatedConnections() - { - return $this->allocated_connections; - } - - /** - * Output only. A list of connections allocated for the Gateway - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway.AllocatedConnection allocated_connections = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\AllocatedConnection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllocatedConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\AllocatedConnection::class); - $this->allocated_connections = $arr; - - return $this; - } - - /** - * Required. The type of hosting used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.HostType host_type = 11 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getHostType() - { - return $this->host_type; - } - - /** - * Required. The type of hosting used by the AppGateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway.HostType host_type = 11 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setHostType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway\HostType::class); - $this->host_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/AllocatedConnection.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/AllocatedConnection.php deleted file mode 100644 index ae86af600c62..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/AllocatedConnection.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGateway.AllocatedConnection - */ -class AllocatedConnection extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The PSC uri of an allocated connection - * - * Generated from protobuf field string psc_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $psc_uri = ''; - /** - * Required. The ingress port of an allocated connection - * - * Generated from protobuf field int32 ingress_port = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ingress_port = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $psc_uri - * Required. The PSC uri of an allocated connection - * @type int $ingress_port - * Required. The ingress port of an allocated connection - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The PSC uri of an allocated connection - * - * Generated from protobuf field string psc_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPscUri() - { - return $this->psc_uri; - } - - /** - * Required. The PSC uri of an allocated connection - * - * Generated from protobuf field string psc_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPscUri($var) - { - GPBUtil::checkString($var, True); - $this->psc_uri = $var; - - return $this; - } - - /** - * Required. The ingress port of an allocated connection - * - * Generated from protobuf field int32 ingress_port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getIngressPort() - { - return $this->ingress_port; - } - - /** - * Required. The ingress port of an allocated connection - * - * Generated from protobuf field int32 ingress_port = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setIngressPort($var) - { - GPBUtil::checkInt32($var); - $this->ingress_port = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AllocatedConnection::class, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway_AllocatedConnection::class); - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/HostType.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/HostType.php deleted file mode 100644 index 0be7ad2a31c9..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/HostType.php +++ /dev/null @@ -1,58 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGateway.HostType - */ -class HostType -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum HOST_TYPE_UNSPECIFIED = 0; - */ - const HOST_TYPE_UNSPECIFIED = 0; - /** - * AppGateway hosted in a GCP regional managed instance group. - * - * Generated from protobuf enum GCP_REGIONAL_MIG = 1; - */ - const GCP_REGIONAL_MIG = 1; - - private static $valueToName = [ - self::HOST_TYPE_UNSPECIFIED => 'HOST_TYPE_UNSPECIFIED', - self::GCP_REGIONAL_MIG => 'GCP_REGIONAL_MIG', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HostType::class, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway_HostType::class); - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/State.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/State.php deleted file mode 100644 index ab280c73a846..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/State.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGateway.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * AppGateway is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * AppGateway has been created. - * - * Generated from protobuf enum CREATED = 2; - */ - const CREATED = 2; - /** - * AppGateway's configuration is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * AppGateway is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * AppGateway is down and may be restored in the future. - * This happens when CCFE sends ProjectState = OFF. - * - * Generated from protobuf enum DOWN = 5; - */ - const DOWN = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::CREATED => 'CREATED', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::DOWN => 'DOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway_State::class); - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/Type.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/Type.php deleted file mode 100644 index 237bf4a3fd35..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway/Type.php +++ /dev/null @@ -1,58 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGateway.Type - */ -class Type -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * TCP Proxy based BeyondCorp Connection. API will default to this if unset. - * - * Generated from protobuf enum TCP_PROXY = 1; - */ - const TCP_PROXY = 1; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::TCP_PROXY => 'TCP_PROXY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway_Type::class); - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGatewayOperationMetadata.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGatewayOperationMetadata.php deleted file mode 100644 index cc45976fe154..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGatewayOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.AppGatewayOperationMetadata - */ -class AppGatewayOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_AllocatedConnection.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_AllocatedConnection.php deleted file mode 100644 index c11f590219a1..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/AppGateway_AllocatedConnection.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/ListAppGateways', - $argument, - ['\Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single AppGateway. - * @param \Google\Cloud\BeyondCorp\AppGateways\V1\GetAppGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetAppGateway(\Google\Cloud\BeyondCorp\AppGateways\V1\GetAppGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/GetAppGateway', - $argument, - ['\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway', 'decode'], - $metadata, $options); - } - - /** - * Creates a new AppGateway in a given project and location. - * @param \Google\Cloud\BeyondCorp\AppGateways\V1\CreateAppGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateAppGateway(\Google\Cloud\BeyondCorp\AppGateways\V1\CreateAppGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/CreateAppGateway', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single AppGateway. - * @param \Google\Cloud\BeyondCorp\AppGateways\V1\DeleteAppGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteAppGateway(\Google\Cloud\BeyondCorp\AppGateways\V1\DeleteAppGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/DeleteAppGateway', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/CreateAppGatewayRequest.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/CreateAppGatewayRequest.php deleted file mode 100644 index 1462f6d587f3..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/CreateAppGatewayRequest.php +++ /dev/null @@ -1,295 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.CreateAppGatewayRequest - */ -class CreateAppGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $app_gateway_id = ''; - /** - * Required. A BeyondCorp AppGateway resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $app_gateway = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * Please see {@see AppGatewaysServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $appGateway Required. A BeyondCorp AppGateway resource. - * @param string $appGatewayId Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\CreateAppGatewayRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $appGateway, string $appGatewayId): self - { - return (new self()) - ->setParent($parent) - ->setAppGateway($appGateway) - ->setAppGatewayId($appGatewayId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * @type string $app_gateway_id - * Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $app_gateway - * Required. A BeyondCorp AppGateway resource. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getAppGatewayId() - { - return $this->app_gateway_id; - } - - /** - * Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string app_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setAppGatewayId($var) - { - GPBUtil::checkString($var, True); - $this->app_gateway_id = $var; - - return $this; - } - - /** - * Required. A BeyondCorp AppGateway resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway|null - */ - public function getAppGateway() - { - return $this->app_gateway; - } - - public function hasAppGateway() - { - return isset($this->app_gateway); - } - - public function clearAppGateway() - { - unset($this->app_gateway); - } - - /** - * Required. A BeyondCorp AppGateway resource. - * - * Generated from protobuf field .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway $var - * @return $this - */ - public function setAppGateway($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway::class); - $this->app_gateway = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/DeleteAppGatewayRequest.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/DeleteAppGatewayRequest.php deleted file mode 100644 index 0dd9bed3f1c3..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/DeleteAppGatewayRequest.php +++ /dev/null @@ -1,198 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.DeleteAppGatewayRequest - */ -class DeleteAppGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $name Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * Please see {@see AppGatewaysServiceClient::appGatewayName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\DeleteAppGatewayRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/GetAppGatewayRequest.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/GetAppGatewayRequest.php deleted file mode 100644 index f19a8b563b82..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/GetAppGatewayRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.GetAppGatewayRequest - */ -class GetAppGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * Please see {@see AppGatewaysServiceClient::appGatewayName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\GetAppGatewayRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysRequest.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysRequest.php deleted file mode 100644 index 7fde412ec54b..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysRequest.php +++ /dev/null @@ -1,258 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.ListAppGatewaysRequest - */ -class ListAppGatewaysRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppGatewaysResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The next_page_token value returned from a previous - * ListAppGatewaysRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * Please see {@see AppGatewaysServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * @type int $page_size - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppGatewaysResponse.next_page_token] to - * determine if there are more instances left to be queried. - * @type string $page_token - * Optional. The next_page_token value returned from a previous - * ListAppGatewaysRequest, if any. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $order_by - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppGatewaysResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of items to return. - * If not specified, a default value of 50 will be used by the service. - * Regardless of the page_size value, the response may include a partial list - * and a caller should only rely on response's - * [next_page_token][BeyondCorp.ListAppGatewaysResponse.next_page_token] to - * determine if there are more instances left to be queried. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppGatewaysRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The next_page_token value returned from a previous - * ListAppGatewaysRequest, if any. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. A filter specifying constraints of a list operation. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysResponse.php b/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysResponse.php deleted file mode 100644 index 757bac5b484a..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/proto/src/Google/Cloud/BeyondCorp/AppGateways/V1/ListAppGatewaysResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.beyondcorp.appgateways.v1.ListAppGatewaysResponse - */ -class ListAppGatewaysResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of BeyondCorp AppGateways in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateways = 1; - */ - private $app_gateways; - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway>|\Google\Protobuf\Internal\RepeatedField $app_gateways - * A list of BeyondCorp AppGateways in the project. - * @type string $next_page_token - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * A list of locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Appgateways\V1\AppGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * A list of BeyondCorp AppGateways in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateways = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAppGateways() - { - return $this->app_gateways; - } - - /** - * A list of BeyondCorp AppGateways in the project. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.appgateways.v1.AppGateway app_gateways = 1; - * @param array<\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAppGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway::class); - $this->app_gateways = $arr; - - return $this; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to retrieve the next page of results, or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/create_app_gateway.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/create_app_gateway.php deleted file mode 100644 index bc8b21f93932..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/create_app_gateway.php +++ /dev/null @@ -1,102 +0,0 @@ -setName($appGatewayName) - ->setType($appGatewayType) - ->setHostType($appGatewayHostType); - $request = (new CreateAppGatewayRequest()) - ->setParent($formattedParent) - ->setAppGateway($appGateway); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appGatewaysServiceClient->createAppGateway($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AppGateway $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 = AppGatewaysServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $appGatewayName = '[NAME]'; - $appGatewayType = Type::TYPE_UNSPECIFIED; - $appGatewayHostType = HostType::HOST_TYPE_UNSPECIFIED; - - create_app_gateway_sample($formattedParent, $appGatewayName, $appGatewayType, $appGatewayHostType); -} -// [END beyondcorp_v1_generated_AppGatewaysService_CreateAppGateway_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php deleted file mode 100644 index 70e09f5c749d..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/delete_app_gateway.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $appGatewaysServiceClient->deleteAppGateway($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 = AppGatewaysServiceClient::appGatewayName( - '[PROJECT]', - '[LOCATION]', - '[APP_GATEWAY]' - ); - - delete_app_gateway_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppGatewaysService_DeleteAppGateway_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_app_gateway.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_app_gateway.php deleted file mode 100644 index de8212fc6fc8..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_app_gateway.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var AppGateway $response */ - $response = $appGatewaysServiceClient->getAppGateway($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 = AppGatewaysServiceClient::appGatewayName( - '[PROJECT]', - '[LOCATION]', - '[APP_GATEWAY]' - ); - - get_app_gateway_sample($formattedName); -} -// [END beyondcorp_v1_generated_AppGatewaysService_GetAppGateway_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_iam_policy.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_iam_policy.php deleted file mode 100644 index 649593fa0277..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_AppGatewaysService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_location.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_location.php deleted file mode 100644 index 846f1bb50132..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppGatewaysService_GetLocation_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_app_gateways.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_app_gateways.php deleted file mode 100644 index 14202545dbb9..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_app_gateways.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $appGatewaysServiceClient->listAppGateways($request); - - /** @var AppGateway $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 = AppGatewaysServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_app_gateways_sample($formattedParent); -} -// [END beyondcorp_v1_generated_AppGatewaysService_ListAppGateways_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_locations.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_locations.php deleted file mode 100644 index 82fee59e6a83..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_AppGatewaysService_ListLocations_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/set_iam_policy.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/set_iam_policy.php deleted file mode 100644 index 939c7626933e..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $appGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_AppGatewaysService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php b/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php deleted file mode 100644 index ba0c7dde8739..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/samples/V1/AppGatewaysServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $appGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_AppGatewaysService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/AppGatewaysServiceClient.php b/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/AppGatewaysServiceClient.php deleted file mode 100644 index f2d79119420d..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/AppGatewaysServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $appGateway = new AppGateway(); - * $operationResponse = $appGatewaysServiceClient->createAppGateway($formattedParent, $appGateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appGatewaysServiceClient->createAppGateway($formattedParent, $appGateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appGatewaysServiceClient->resumeOperation($operationName, 'createAppGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * 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. - */ -class AppGatewaysServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.beyondcorp.appgateways.v1.AppGatewaysService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'beyondcorp.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $appGatewayNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/app_gateways_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/app_gateways_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/app_gateways_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/app_gateways_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getAppGatewayNameTemplate() - { - if (self::$appGatewayNameTemplate == null) { - self::$appGatewayNameTemplate = new PathTemplate('projects/{project}/locations/{location}/appGateways/{app_gateway}'); - } - - return self::$appGatewayNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'appGateway' => self::getAppGatewayNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a app_gateway - * resource. - * - * @param string $project - * @param string $location - * @param string $appGateway - * - * @return string The formatted app_gateway resource. - */ - public static function appGatewayName($project, $location, $appGateway) - { - return self::getAppGatewayNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'app_gateway' => $appGateway, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - appGateway: projects/{project}/locations/{location}/appGateways/{app_gateway} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'beyondcorp.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new AppGateway in a given project and location. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $formattedParent = $appGatewaysServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $appGateway = new AppGateway(); - * $operationResponse = $appGatewaysServiceClient->createAppGateway($formattedParent, $appGateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appGatewaysServiceClient->createAppGateway($formattedParent, $appGateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appGatewaysServiceClient->resumeOperation($operationName, 'createAppGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource project name of the AppGateway location using the - * form: `projects/{project_id}/locations/{location_id}` - * @param AppGateway $appGateway Required. A BeyondCorp AppGateway resource. - * @param array $optionalArgs { - * Optional. - * - * @type string $appGatewayId - * Optional. User-settable AppGateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createAppGateway($parent, $appGateway, array $optionalArgs = []) - { - $request = new CreateAppGatewayRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAppGateway($appGateway); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['appGatewayId'])) { - $request->setAppGatewayId($optionalArgs['appGatewayId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateAppGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single AppGateway. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $formattedName = $appGatewaysServiceClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - * $operationResponse = $appGatewaysServiceClient->deleteAppGateway($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $appGatewaysServiceClient->deleteAppGateway($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $appGatewaysServiceClient->resumeOperation($operationName, 'deleteAppGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteAppGateway($name, array $optionalArgs = []) - { - $request = new DeleteAppGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteAppGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single AppGateway. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $formattedName = $appGatewaysServiceClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - * $response = $appGatewaysServiceClient->getAppGateway($formattedName); - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $name Required. BeyondCorp AppGateway name using the form: - * `projects/{project_id}/locations/{location_id}/appGateways/{app_gateway_id}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway - * - * @throws ApiException if the remote call fails - */ - public function getAppGateway($name, array $optionalArgs = []) - { - $request = new GetAppGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetAppGateway', AppGateway::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists AppGateways in a given project and location. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $formattedParent = $appGatewaysServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $appGatewaysServiceClient->listAppGateways($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appGatewaysServiceClient->listAppGateways($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource name of the AppGateway location using the form: - * `projects/{project_id}/locations/{location_id}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. A filter specifying constraints of a list operation. - * @type string $orderBy - * Optional. Specifies the ordering of results. See - * [Sorting - * order](https://cloud.google.com/apis/design/design_patterns#sorting_order) - * for more information. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listAppGateways($parent, array $optionalArgs = []) - { - $request = new ListAppGatewaysRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAppGateways', $optionalArgs, ListAppGatewaysResponse::class, $request); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $response = $appGatewaysServiceClient->getLocation(); - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $appGatewaysServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $appGatewaysServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $response = $appGatewaysServiceClient->getIamPolicy($resource); - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $appGatewaysServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $appGatewaysServiceClient = new AppGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $appGatewaysServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $appGatewaysServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 7a4405a3cc86..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.beyondcorp.appgateways.v1", - "libraryPackage": "Google\\Cloud\\BeyondCorp\\AppGateways\\V1", - "services": { - "AppGatewaysService": { - "clients": { - "grpc": { - "libraryClient": "AppGatewaysServiceGapicClient", - "rpcs": { - "CreateAppGateway": { - "methods": [ - "createAppGateway" - ] - }, - "DeleteAppGateway": { - "methods": [ - "deleteAppGateway" - ] - }, - "GetAppGateway": { - "methods": [ - "getAppGateway" - ] - }, - "ListAppGateways": { - "methods": [ - "listAppGateways" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_client_config.json b/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_client_config.json deleted file mode 100644 index 17dd44bd7ca4..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_client_config.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - "interfaces": { - "google.cloud.beyondcorp.appgateways.v1.AppGatewaysService": { - "retry_codes": { - "no_retry_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - } - }, - "methods": { - "CreateAppGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteAppGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetAppGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListAppGateways": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_descriptor_config.php b/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_descriptor_config.php deleted file mode 100644 index 270c9a8fe5da..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_descriptor_config.php +++ /dev/null @@ -1,155 +0,0 @@ - [ - 'google.cloud.beyondcorp.appgateways.v1.AppGatewaysService' => [ - 'CreateAppGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewayOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\AppGateways\V1\AppGatewayOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetAppGateway' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppGateways\V1\AppGateway', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAppGateways' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAppGateways', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\AppGateways\V1\ListAppGatewaysResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'appGateway' => 'projects/{project}/locations/{location}/appGateways/{app_gateway}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_rest_client_config.php b/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_rest_client_config.php deleted file mode 100644 index 11864d505ad2..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/src/V1/resources/app_gateways_service_rest_client_config.php +++ /dev/null @@ -1,224 +0,0 @@ - [ - 'google.cloud.beyondcorp.appgateways.v1.AppGatewaysService' => [ - 'CreateAppGateway' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appGateways', - 'body' => 'app_gateway', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteAppGateway' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appGateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetAppGateway' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/appGateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAppGateways' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/appGateways', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/AppGatewaysServiceClientTest.php b/owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/AppGatewaysServiceClientTest.php deleted file mode 100644 index e371358131ef..000000000000 --- a/owl-bot-staging/BeyondCorpAppGateways/v1/tests/Unit/V1/AppGatewaysServiceClientTest.php +++ /dev/null @@ -1,775 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AppGatewaysServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AppGatewaysServiceClient($options); - } - - /** @test */ - public function createAppGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $uri = 'uri116076'; - $expectedResponse = new AppGateway(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $expectedResponse->setUri($uri); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAppGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appGateway = new AppGateway(); - $appGatewayName = 'appGatewayName-1786203634'; - $appGateway->setName($appGatewayName); - $appGatewayType = Type::TYPE_UNSPECIFIED; - $appGateway->setType($appGatewayType); - $appGatewayHostType = HostType::HOST_TYPE_UNSPECIFIED; - $appGateway->setHostType($appGatewayHostType); - $response = $gapicClient->createAppGateway($formattedParent, $appGateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/CreateAppGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAppGateway(); - $this->assertProtobufEquals($appGateway, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppGatewayTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAppGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAppGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $appGateway = new AppGateway(); - $appGatewayName = 'appGatewayName-1786203634'; - $appGateway->setName($appGatewayName); - $appGatewayType = Type::TYPE_UNSPECIFIED; - $appGateway->setType($appGatewayType); - $appGatewayHostType = HostType::HOST_TYPE_UNSPECIFIED; - $appGateway->setHostType($appGatewayHostType); - $response = $gapicClient->createAppGateway($formattedParent, $appGateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAppGatewayTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteAppGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - $response = $gapicClient->deleteAppGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/DeleteAppGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppGatewayTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteAppGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteAppGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - $response = $gapicClient->deleteAppGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteAppGatewayTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAppGatewayTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $uri = 'uri116076'; - $expectedResponse = new AppGateway(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $expectedResponse->setUri($uri); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - $response = $gapicClient->getAppGateway($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/GetAppGateway', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAppGatewayExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->appGatewayName('[PROJECT]', '[LOCATION]', '[APP_GATEWAY]'); - try { - $gapicClient->getAppGateway($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppGatewaysTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $appGatewaysElement = new AppGateway(); - $appGateways = [ - $appGatewaysElement, - ]; - $expectedResponse = new ListAppGatewaysResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAppGateways($appGateways); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listAppGateways($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAppGateways()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.appgateways.v1.AppGatewaysService/ListAppGateways', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAppGatewaysExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listAppGateways($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientconnectorservices/V1/ClientConnectorServicesService.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientconnectorservices/V1/ClientConnectorServicesService.php deleted file mode 100644 index 5fb59d23e6f62fa4b59deb7e0936779a3fe408f4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6575 zcmcIpO>Em#94ASewy)dh9&Dr;A0{1I8N;CgA(YZFr_D-H*MuzV#E4`$&P(gnwTfR)RwH5#_!|*@%w+i_g;O? zS$EKsv`8%CYCdU6%^k^KCz9jZzOCD))a$YVP-M3wjxLbx!y!_UTm{P+zHJA*3 z$V?1`ENzo`j;0f7v0A!De66MVT4RxMY|K-RjZ(-F1|m5&R%d1r(oN0tB)()m5bC-R zO8iH=NP<77(=-iT@_fyQf9DNPH7vt7G}CwwfSQxqn&}ZBd2nsJW9hzOTN2$+v2-&1 zti);3wdWlhfSr>91*#Nlz`3zx`NXv}v#~%t-8CG5s|rht#WmuG7NR55&kDAboY9u1 zxs1i)0U_rk-|diI?vmsZzvEi7Om0eGFZ|VrfLC#hhGJPZMZvbbVzH}Jmqgq~j`Pv> zTs4Tjt>D zuWdTfdzrsHf7uY;p|o0|GhBt3oDR)Ljd=lm^c=eN;DQksIBl5)y4($P7>Eozd21&7 zn2<+v3=#A^va?V1Oth)p)uu4KSTNbMz!laNQ&VEf?3yrdhb9z@g0#dE3B*{QbJ+w# z?Gqtf;Rn{>3v$1XqqEWZ0-r`hG&N-sQet|nl=@vs;+N34?h;6)Dy5T2!pwLfD|1;n zMG!*{O-^^E=&p_fNlolZ9d6eoI?*yb$JBOICdN=8Mgp&+5pZch%*&)1v05O)5$q;M zt1T~a%3R?#N)yg#gfV(^fQ-tFFz3@k!!*m0%qXxqRj3Y-&2>tb86x}b5E>Ec;SH3A z($qHAn0?0!Zw-*8;2}c^0tT-?l)aNeY5svfO(5*Mn&mmR>#NK!p%OD8P8BvDm=JP3 z;K>pbuq>s)qkmV1@rNK$3sRI}vHYmIcE=|kICl!1`}TvA2QZ@O;vqbOQuX=jM4~i-P8mD~X!8OF%zl?ZY3{A~9fTZ0T+&jv99_81+XKXivyrQe z$Eu@)^E`vb!cUw*lI&Vi=F1;c~53sZFGd zpC$fMK1rY#dWr_mi%=Il8CuMIbi%>6AP8OmXH+;W(@bpk&IenZE7dxKaRS^}8a68I66ZW|`FhMArOe+G@(Zi~2Tb0;$#uFd_J zKvR9Sfuv%21aG3rI7mFukjC{JgY#L??O}_&3(2gjAgzpJpxb!If_ka1YfY1Y)~V?+ z@JTq3#26&7$JP5vudv3^T`TuP5>3ssf*tJu0l&f7e;S>OgI+aS-9(juOp=LP$^2uW zHsVzloY3VSPi5)xw=6oj1t%ZYqu7?ooo56@ z?7<;0L)%%Ffm4O=PogKIf$>C%!CxlPxju;(uO26x_8}GBGZTYmqSKR-{- z;aPf9v&(DWTv&%M_SD~tv32*JB8n#dAc-bpb2_dcM~PT+0WI{j z?5f~kHx@eq#ptf0#GbMY*k5R#AQdi{)YK91KV zaV0^E^c znT$Oq{jA9AzVCR&e13a-Tf}sDhSECzI%FZZ6n`GBhWxheZkGN|qL<-(6@>p0?tn^D z{R}@o1W#??87_*fY{+n0Gy@oegoogle.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService - */ -class ClientConnectorService extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. User-provided name. - * The display name should follow certain format. - * * Must be 6 to 30 characters in length. - * * Can only contain lowercase letters, numbers, and hyphens. - * * Must start with a letter. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Required. The details of the ingress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress ingress = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ingress = null; - /** - * Required. The details of the egress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress egress = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $egress = null; - /** - * Output only. The operational state of the ClientConnectorService. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of resource. The name is ignored during creation. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. [Output only] Create time stamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. [Output only] Update time stamp. - * @type string $display_name - * Optional. User-provided name. - * The display name should follow certain format. - * * Must be 6 to 30 characters in length. - * * Can only contain lowercase letters, numbers, and hyphens. - * * Must start with a letter. - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress $ingress - * Required. The details of the ingress settings. - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress $egress - * Required. The details of the egress settings. - * @type int $state - * Output only. The operational state of the ClientConnectorService. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Optional. User-provided name. - * The display name should follow certain format. - * * Must be 6 to 30 characters in length. - * * Can only contain lowercase letters, numbers, and hyphens. - * * Must start with a letter. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. User-provided name. - * The display name should follow certain format. - * * Must be 6 to 30 characters in length. - * * Can only contain lowercase letters, numbers, and hyphens. - * * Must start with a letter. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Required. The details of the ingress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress ingress = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress|null - */ - public function getIngress() - { - return $this->ingress; - } - - public function hasIngress() - { - return isset($this->ingress); - } - - public function clearIngress() - { - unset($this->ingress); - } - - /** - * Required. The details of the ingress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress ingress = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress $var - * @return $this - */ - public function setIngress($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress::class); - $this->ingress = $var; - - return $this; - } - - /** - * Required. The details of the egress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress egress = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress|null - */ - public function getEgress() - { - return $this->egress; - } - - public function hasEgress() - { - return isset($this->egress); - } - - public function clearEgress() - { - unset($this->egress); - } - - /** - * Required. The details of the egress settings. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress egress = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress $var - * @return $this - */ - public function setEgress($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress::class); - $this->egress = $var; - - return $this; - } - - /** - * Output only. The operational state of the ClientConnectorService. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The operational state of the ClientConnectorService. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress.php deleted file mode 100644 index 44f15504298f..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress - */ -class Egress extends \Google\Protobuf\Internal\Message -{ - protected $destination_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress\PeeredVpc $peered_vpc - * A VPC from the consumer project. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * A VPC from the consumer project. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress.PeeredVpc peered_vpc = 1; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress\PeeredVpc|null - */ - public function getPeeredVpc() - { - return $this->readOneof(1); - } - - public function hasPeeredVpc() - { - return $this->hasOneof(1); - } - - /** - * A VPC from the consumer project. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress.PeeredVpc peered_vpc = 1; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress\PeeredVpc $var - * @return $this - */ - public function setPeeredVpc($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Egress\PeeredVpc::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getDestinationType() - { - return $this->whichOneof("destination_type"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Egress::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Egress::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress/PeeredVpc.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress/PeeredVpc.php deleted file mode 100644 index cb600f930cf7..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Egress/PeeredVpc.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Egress.PeeredVpc - */ -class PeeredVpc extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the peered VPC owned by the consumer project. - * - * Generated from protobuf field string network_vpc = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_vpc = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network_vpc - * Required. The name of the peered VPC owned by the consumer project. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the peered VPC owned by the consumer project. - * - * Generated from protobuf field string network_vpc = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNetworkVpc() - { - return $this->network_vpc; - } - - /** - * Required. The name of the peered VPC owned by the consumer project. - * - * Generated from protobuf field string network_vpc = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNetworkVpc($var) - { - GPBUtil::checkString($var, True); - $this->network_vpc = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PeeredVpc::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Egress_PeeredVpc::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress.php deleted file mode 100644 index 3d5145bd439d..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress - */ -class Ingress extends \Google\Protobuf\Internal\Message -{ - protected $ingress_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config $config - * The basic ingress config for ClientGateways. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * The basic ingress config for ClientGateways. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config config = 1; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config|null - */ - public function getConfig() - { - return $this->readOneof(1); - } - - public function hasConfig() - { - return $this->hasOneof(1); - } - - /** - * The basic ingress config for ClientGateways. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config config = 1; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getIngressConfig() - { - return $this->whichOneof("ingress_config"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Ingress::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Ingress::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config.php deleted file mode 100644 index ed18102df8ba..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config - */ -class Config extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Immutable. The transport protocol used between the client and - * the server. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $transport_protocol = 0; - /** - * Required. The settings used to configure basic ClientGateways. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $destination_routes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $transport_protocol - * Required. Immutable. The transport protocol used between the client and - * the server. - * @type array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute>|\Google\Protobuf\Internal\RepeatedField $destination_routes - * Required. The settings used to configure basic ClientGateways. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Immutable. The transport protocol used between the client and - * the server. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getTransportProtocol() - { - return $this->transport_protocol; - } - - /** - * Required. Immutable. The transport protocol used between the client and - * the server. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setTransportProtocol($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\TransportProtocol::class); - $this->transport_protocol = $var; - - return $this; - } - - /** - * Required. The settings used to configure basic ClientGateways. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDestinationRoutes() - { - return $this->destination_routes; - } - - /** - * Required. The settings used to configure basic ClientGateways. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDestinationRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute::class); - $this->destination_routes = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Config::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Ingress_Config::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/DestinationRoute.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/DestinationRoute.php deleted file mode 100644 index 42f139cc3904..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/DestinationRoute.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute - */ -class DestinationRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The network address of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $address = ''; - /** - * Required. The network mask of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string netmask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $netmask = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $address - * Required. The network address of the subnet - * for which the packet is routed to the ClientGateway. - * @type string $netmask - * Required. The network mask of the subnet - * for which the packet is routed to the ClientGateway. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The network address of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAddress() - { - return $this->address; - } - - /** - * Required. The network address of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string address = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAddress($var) - { - GPBUtil::checkString($var, True); - $this->address = $var; - - return $this; - } - - /** - * Required. The network mask of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string netmask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNetmask() - { - return $this->netmask; - } - - /** - * Required. The network mask of the subnet - * for which the packet is routed to the ClientGateway. - * - * Generated from protobuf field string netmask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNetmask($var) - { - GPBUtil::checkString($var, True); - $this->netmask = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DestinationRoute::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Ingress_Config_DestinationRoute::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/TransportProtocol.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/TransportProtocol.php deleted file mode 100644 index 988fe0a16327..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/Ingress/Config/TransportProtocol.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol - */ -class TransportProtocol -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum TRANSPORT_PROTOCOL_UNSPECIFIED = 0; - */ - const TRANSPORT_PROTOCOL_UNSPECIFIED = 0; - /** - * TCP protocol. - * - * Generated from protobuf enum TCP = 1; - */ - const TCP = 1; - - private static $valueToName = [ - self::TRANSPORT_PROTOCOL_UNSPECIFIED => 'TRANSPORT_PROTOCOL_UNSPECIFIED', - self::TCP => 'TCP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TransportProtocol::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_Ingress_Config_TransportProtocol::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/State.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/State.php deleted file mode 100644 index effe28bb052a..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService/State.php +++ /dev/null @@ -1,94 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * ClientConnectorService is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * ClientConnectorService is being updated. - * - * Generated from protobuf enum UPDATING = 2; - */ - const UPDATING = 2; - /** - * ClientConnectorService is being deleted. - * - * Generated from protobuf enum DELETING = 3; - */ - const DELETING = 3; - /** - * ClientConnectorService is running. - * - * Generated from protobuf enum RUNNING = 4; - */ - const RUNNING = 4; - /** - * ClientConnectorService is down and may be restored in the future. - * This happens when CCFE sends ProjectState = OFF. - * - * Generated from protobuf enum DOWN = 5; - */ - const DOWN = 5; - /** - * ClientConnectorService encountered an error and is in an indeterministic - * state. - * - * Generated from protobuf enum ERROR = 6; - */ - const ERROR = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::RUNNING => 'RUNNING', - self::DOWN => 'DOWN', - self::ERROR => 'ERROR', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService_State::class); - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorServiceOperationMetadata.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorServiceOperationMetadata.php deleted file mode 100644 index 844551d17009..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorServiceOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServiceOperationMetadata - */ -class ClientConnectorServiceOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Egress.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Egress.php deleted file mode 100644 index cf0a5f0e1db8..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ClientConnectorService_Egress.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/ListClientConnectorServices', - $argument, - ['\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single ClientConnectorService. - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\GetClientConnectorServiceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetClientConnectorService(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\GetClientConnectorServiceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/GetClientConnectorService', - $argument, - ['\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService', 'decode'], - $metadata, $options); - } - - /** - * Creates a new ClientConnectorService in a given project and location. - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\CreateClientConnectorServiceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateClientConnectorService(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\CreateClientConnectorServiceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/CreateClientConnectorService', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates the parameters of a single ClientConnectorService. - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\UpdateClientConnectorServiceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateClientConnectorService(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\UpdateClientConnectorServiceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/UpdateClientConnectorService', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single ClientConnectorService. - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\DeleteClientConnectorServiceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteClientConnectorService(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\DeleteClientConnectorServiceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/DeleteClientConnectorService', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/CreateClientConnectorServiceRequest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/CreateClientConnectorServiceRequest.php deleted file mode 100644 index 0a95214649da..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/CreateClientConnectorServiceRequest.php +++ /dev/null @@ -1,301 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.CreateClientConnectorServiceRequest - */ -class CreateClientConnectorServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * A random system generated name will be assigned - * if not specified by the user. - * - * Generated from protobuf field string client_connector_service_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $client_connector_service_id = ''; - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $client_connector_service = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. Value for parent. Please see - * {@see ClientConnectorServicesServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService Required. The resource being created. - * @param string $clientConnectorServiceId Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * A random system generated name will be assigned - * if not specified by the user. - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\CreateClientConnectorServiceRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService, string $clientConnectorServiceId): self - { - return (new self()) - ->setParent($parent) - ->setClientConnectorService($clientConnectorService) - ->setClientConnectorServiceId($clientConnectorServiceId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Value for parent. - * @type string $client_connector_service_id - * Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * A random system generated name will be assigned - * if not specified by the user. - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $client_connector_service - * Required. The resource being created. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * A random system generated name will be assigned - * if not specified by the user. - * - * Generated from protobuf field string client_connector_service_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getClientConnectorServiceId() - { - return $this->client_connector_service_id; - } - - /** - * Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * A random system generated name will be assigned - * if not specified by the user. - * - * Generated from protobuf field string client_connector_service_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setClientConnectorServiceId($var) - { - GPBUtil::checkString($var, True); - $this->client_connector_service_id = $var; - - return $this; - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService|null - */ - public function getClientConnectorService() - { - return $this->client_connector_service; - } - - public function hasClientConnectorService() - { - return isset($this->client_connector_service); - } - - public function clearClientConnectorService() - { - unset($this->client_connector_service); - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $var - * @return $this - */ - public function setClientConnectorService($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService::class); - $this->client_connector_service = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/DeleteClientConnectorServiceRequest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/DeleteClientConnectorServiceRequest.php deleted file mode 100644 index 191baa3fdc0e..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/DeleteClientConnectorServiceRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.DeleteClientConnectorServiceRequest - */ -class DeleteClientConnectorServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see ClientConnectorServicesServiceClient::clientConnectorServiceName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\DeleteClientConnectorServiceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/GetClientConnectorServiceRequest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/GetClientConnectorServiceRequest.php deleted file mode 100644 index 375cdd935d62..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/GetClientConnectorServiceRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.GetClientConnectorServiceRequest - */ -class GetClientConnectorServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see ClientConnectorServicesServiceClient::clientConnectorServiceName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\GetClientConnectorServiceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesRequest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesRequest.php deleted file mode 100644 index 5f92bfb0a749..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ListClientConnectorServicesRequest - */ -class ListClientConnectorServicesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListClientConnectorServicesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Parent value for ListClientConnectorServicesRequest. Please see - * {@see ClientConnectorServicesServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListClientConnectorServicesRequest. - * @type int $page_size - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * @type string $page_token - * Optional. A token identifying a page of results the server should return. - * @type string $filter - * Optional. Filtering results. - * @type string $order_by - * Optional. Hint for how to order the results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListClientConnectorServicesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListClientConnectorServicesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesResponse.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesResponse.php deleted file mode 100644 index 606e1598f06e..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/ListClientConnectorServicesResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.ListClientConnectorServicesResponse - */ -class ListClientConnectorServicesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of ClientConnectorService. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_services = 1; - */ - private $client_connector_services; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService>|\Google\Protobuf\Internal\RepeatedField $client_connector_services - * The list of ClientConnectorService. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * The list of ClientConnectorService. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_services = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getClientConnectorServices() - { - return $this->client_connector_services; - } - - /** - * The list of ClientConnectorService. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_services = 1; - * @param array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setClientConnectorServices($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService::class); - $this->client_connector_services = $arr; - - return $this; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/UpdateClientConnectorServiceRequest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/UpdateClientConnectorServiceRequest.php deleted file mode 100644 index d972d609914e..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/proto/src/Google/Cloud/BeyondCorp/ClientConnectorServices/V1/UpdateClientConnectorServiceRequest.php +++ /dev/null @@ -1,308 +0,0 @@ -google.cloud.beyondcorp.clientconnectorservices.v1.UpdateClientConnectorServiceRequest - */ -class UpdateClientConnectorServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * Mutable fields: display_name. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $client_connector_service = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService Required. The resource being updated. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * - * Mutable fields: display_name. - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\UpdateClientConnectorServiceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $clientConnectorService, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setClientConnectorService($clientConnectorService) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * Mutable fields: display_name. - * @type \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $client_connector_service - * Required. The resource being updated. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type bool $allow_missing - * Optional. If set as true, will create the resource if it is not found. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * Mutable fields: display_name. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * Mutable fields: display_name. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService|null - */ - public function getClientConnectorService() - { - return $this->client_connector_service; - } - - public function hasClientConnectorService() - { - return isset($this->client_connector_service); - } - - public function clearClientConnectorService() - { - unset($this->client_connector_service); - } - - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService client_connector_service = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService $var - * @return $this - */ - public function setClientConnectorService($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService::class); - $this->client_connector_service = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * Optional. If set as true, will create the resource if it is not found. - * - * Generated from protobuf field bool allow_missing = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php deleted file mode 100644 index 13bbd0aedb8f..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/create_client_connector_service.php +++ /dev/null @@ -1,96 +0,0 @@ -setName($clientConnectorServiceName) - ->setIngress($clientConnectorServiceIngress) - ->setEgress($clientConnectorServiceEgress); - $request = (new CreateClientConnectorServiceRequest()) - ->setParent($formattedParent) - ->setClientConnectorService($clientConnectorService); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->createClientConnectorService($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ClientConnectorService $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 = ClientConnectorServicesServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $clientConnectorServiceName = '[NAME]'; - - create_client_connector_service_sample($formattedParent, $clientConnectorServiceName); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_CreateClientConnectorService_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php deleted file mode 100644 index 09b94f3f081e..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/delete_client_connector_service.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->deleteClientConnectorService($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 = ClientConnectorServicesServiceClient::clientConnectorServiceName( - '[PROJECT]', - '[LOCATION]', - '[CLIENT_CONNECTOR_SERVICE]' - ); - - delete_client_connector_service_sample($formattedName); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_DeleteClientConnectorService_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php deleted file mode 100644 index bf2c183568ac..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_client_connector_service.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ClientConnectorService $response */ - $response = $clientConnectorServicesServiceClient->getClientConnectorService($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 = ClientConnectorServicesServiceClient::clientConnectorServiceName( - '[PROJECT]', - '[LOCATION]', - '[CLIENT_CONNECTOR_SERVICE]' - ); - - get_client_connector_service_sample($formattedName); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_GetClientConnectorService_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php deleted file mode 100644 index fb48b5ef5114..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $clientConnectorServicesServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_location.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_location.php deleted file mode 100644 index d8dd61d5a3c7..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_GetLocation_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php deleted file mode 100644 index 8bbe2319abab..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_client_connector_services.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $clientConnectorServicesServiceClient->listClientConnectorServices($request); - - /** @var ClientConnectorService $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 = ClientConnectorServicesServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_client_connector_services_sample($formattedParent); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_ListClientConnectorServices_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_locations.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_locations.php deleted file mode 100644 index bfdb49122c4b..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_ListLocations_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php deleted file mode 100644 index ccfc35bb5287..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $clientConnectorServicesServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php deleted file mode 100644 index 5c707c8b798c..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $clientConnectorServicesServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php deleted file mode 100644 index 55d3e069fbd9..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/samples/V1/ClientConnectorServicesServiceClient/update_client_connector_service.php +++ /dev/null @@ -1,93 +0,0 @@ -setName($clientConnectorServiceName) - ->setIngress($clientConnectorServiceIngress) - ->setEgress($clientConnectorServiceEgress); - $request = (new UpdateClientConnectorServiceRequest()) - ->setUpdateMask($updateMask) - ->setClientConnectorService($clientConnectorService); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $clientConnectorServicesServiceClient->updateClientConnectorService($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ClientConnectorService $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 -{ - $clientConnectorServiceName = '[NAME]'; - - update_client_connector_service_sample($clientConnectorServiceName); -} -// [END beyondcorp_v1_generated_ClientConnectorServicesService_UpdateClientConnectorService_sync] diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/ClientConnectorServicesServiceClient.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/ClientConnectorServicesServiceClient.php deleted file mode 100644 index d27e6ea60eb5..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/ClientConnectorServicesServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $clientConnectorService = new ClientConnectorService(); - * $operationResponse = $clientConnectorServicesServiceClient->createClientConnectorService($formattedParent, $clientConnectorService); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientConnectorServicesServiceClient->createClientConnectorService($formattedParent, $clientConnectorService); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientConnectorServicesServiceClient->resumeOperation($operationName, 'createClientConnectorService'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * 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. - */ -class ClientConnectorServicesServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'beyondcorp.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $clientConnectorServiceNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/client_connector_services_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/client_connector_services_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/client_connector_services_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/client_connector_services_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getClientConnectorServiceNameTemplate() - { - if (self::$clientConnectorServiceNameTemplate == null) { - self::$clientConnectorServiceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/clientConnectorServices/{client_connector_service}'); - } - - return self::$clientConnectorServiceNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'clientConnectorService' => self::getClientConnectorServiceNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * client_connector_service resource. - * - * @param string $project - * @param string $location - * @param string $clientConnectorService - * - * @return string The formatted client_connector_service resource. - */ - public static function clientConnectorServiceName($project, $location, $clientConnectorService) - { - return self::getClientConnectorServiceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'client_connector_service' => $clientConnectorService, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - clientConnectorService: projects/{project}/locations/{location}/clientConnectorServices/{client_connector_service} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'beyondcorp.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new ClientConnectorService in a given project and location. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $formattedParent = $clientConnectorServicesServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $clientConnectorService = new ClientConnectorService(); - * $operationResponse = $clientConnectorServicesServiceClient->createClientConnectorService($formattedParent, $clientConnectorService); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientConnectorServicesServiceClient->createClientConnectorService($formattedParent, $clientConnectorService); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientConnectorServicesServiceClient->resumeOperation($operationName, 'createClientConnectorService'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Value for parent. - * @param ClientConnectorService $clientConnectorService Required. The resource being created. - * @param array $optionalArgs { - * Optional. - * - * @type string $clientConnectorServiceId - * Optional. User-settable client connector service resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * A random system generated name will be assigned - * if not specified by the user. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createClientConnectorService($parent, $clientConnectorService, array $optionalArgs = []) - { - $request = new CreateClientConnectorServiceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setClientConnectorService($clientConnectorService); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['clientConnectorServiceId'])) { - $request->setClientConnectorServiceId($optionalArgs['clientConnectorServiceId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateClientConnectorService', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single ClientConnectorService. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $formattedName = $clientConnectorServicesServiceClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - * $operationResponse = $clientConnectorServicesServiceClient->deleteClientConnectorService($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientConnectorServicesServiceClient->deleteClientConnectorService($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientConnectorServicesServiceClient->resumeOperation($operationName, 'deleteClientConnectorService'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteClientConnectorService($name, array $optionalArgs = []) - { - $request = new DeleteClientConnectorServiceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteClientConnectorService', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single ClientConnectorService. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $formattedName = $clientConnectorServicesServiceClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - * $response = $clientConnectorServicesServiceClient->getClientConnectorService($formattedName); - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService - * - * @throws ApiException if the remote call fails - */ - public function getClientConnectorService($name, array $optionalArgs = []) - { - $request = new GetClientConnectorServiceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetClientConnectorService', ClientConnectorService::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists ClientConnectorServices in a given project and location. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $formattedParent = $clientConnectorServicesServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $clientConnectorServicesServiceClient->listClientConnectorServices($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $clientConnectorServicesServiceClient->listClientConnectorServices($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListClientConnectorServicesRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. Filtering results. - * @type string $orderBy - * Optional. Hint for how to order the results. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listClientConnectorServices($parent, array $optionalArgs = []) - { - $request = new ListClientConnectorServicesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListClientConnectorServices', $optionalArgs, ListClientConnectorServicesResponse::class, $request); - } - - /** - * Updates the parameters of a single ClientConnectorService. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $clientConnectorService = new ClientConnectorService(); - * $operationResponse = $clientConnectorServicesServiceClient->updateClientConnectorService($updateMask, $clientConnectorService); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientConnectorServicesServiceClient->updateClientConnectorService($updateMask, $clientConnectorService); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientConnectorServicesServiceClient->resumeOperation($operationName, 'updateClientConnectorService'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * ClientConnectorService resource by the update. - * The fields specified in the update_mask are relative to the resource, not - * the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields will be overwritten. - * - * Mutable fields: display_name. - * @param ClientConnectorService $clientConnectorService Required. The resource being updated. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type bool $allowMissing - * Optional. If set as true, will create the resource if it is not found. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateClientConnectorService($updateMask, $clientConnectorService, array $optionalArgs = []) - { - $request = new UpdateClientConnectorServiceRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setClientConnectorService($clientConnectorService); - $requestParamHeaders['client_connector_service.name'] = $clientConnectorService->getName(); - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateClientConnectorService', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $response = $clientConnectorServicesServiceClient->getLocation(); - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $clientConnectorServicesServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $clientConnectorServicesServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $resource = 'resource'; - * $response = $clientConnectorServicesServiceClient->getIamPolicy($resource); - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $clientConnectorServicesServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $clientConnectorServicesServiceClient = new ClientConnectorServicesServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $clientConnectorServicesServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $clientConnectorServicesServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 720b69b26a56..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.beyondcorp.clientconnectorservices.v1", - "libraryPackage": "Google\\Cloud\\BeyondCorp\\ClientConnectorServices\\V1", - "services": { - "ClientConnectorServicesService": { - "clients": { - "grpc": { - "libraryClient": "ClientConnectorServicesServiceGapicClient", - "rpcs": { - "CreateClientConnectorService": { - "methods": [ - "createClientConnectorService" - ] - }, - "DeleteClientConnectorService": { - "methods": [ - "deleteClientConnectorService" - ] - }, - "GetClientConnectorService": { - "methods": [ - "getClientConnectorService" - ] - }, - "ListClientConnectorServices": { - "methods": [ - "listClientConnectorServices" - ] - }, - "UpdateClientConnectorService": { - "methods": [ - "updateClientConnectorService" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_client_config.json b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_client_config.json deleted file mode 100644 index 28b8380f1ff7..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_client_config.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "interfaces": { - "google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService": { - "retry_codes": { - "no_retry_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - } - }, - "methods": { - "CreateClientConnectorService": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteClientConnectorService": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetClientConnectorService": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListClientConnectorServices": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "UpdateClientConnectorService": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_descriptor_config.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_descriptor_config.php deleted file mode 100644 index 593d5772ad92..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_descriptor_config.php +++ /dev/null @@ -1,175 +0,0 @@ - [ - 'google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService' => [ - 'CreateClientConnectorService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServiceOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteClientConnectorService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServiceOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateClientConnectorService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorServiceOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'client_connector_service.name', - 'fieldAccessors' => [ - 'getClientConnectorService', - 'getName', - ], - ], - ], - ], - 'GetClientConnectorService' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListClientConnectorServices' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getClientConnectorServices', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ListClientConnectorServicesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'clientConnectorService' => 'projects/{project}/locations/{location}/clientConnectorServices/{client_connector_service}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_rest_client_config.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_rest_client_config.php deleted file mode 100644 index 6875e581606c..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/src/V1/resources/client_connector_services_service_rest_client_config.php +++ /dev/null @@ -1,240 +0,0 @@ - [ - 'google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService' => [ - 'CreateClientConnectorService' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/clientConnectorServices', - 'body' => 'client_connector_service', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteClientConnectorService' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/clientConnectorServices/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetClientConnectorService' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/clientConnectorServices/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListClientConnectorServices' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/clientConnectorServices', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateClientConnectorService' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{client_connector_service.name=projects/*/locations/*/clientConnectorServices/*}', - 'body' => 'client_connector_service', - 'placeholders' => [ - 'client_connector_service.name' => [ - 'getters' => [ - 'getClientConnectorService', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/ClientConnectorServicesServiceClientTest.php b/owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/ClientConnectorServicesServiceClientTest.php deleted file mode 100644 index a77e8e259f9c..000000000000 --- a/owl-bot-staging/BeyondCorpClientConnectorServices/v1/tests/Unit/V1/ClientConnectorServicesServiceClientTest.php +++ /dev/null @@ -1,905 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ClientConnectorServicesServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ClientConnectorServicesServiceClient($options); - } - - /** @test */ - public function createClientConnectorServiceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new ClientConnectorService(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createClientConnectorServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $clientConnectorService = new ClientConnectorService(); - $clientConnectorServiceName = 'clientConnectorServiceName1804966078'; - $clientConnectorService->setName($clientConnectorServiceName); - $clientConnectorServiceIngress = new Ingress(); - $clientConnectorService->setIngress($clientConnectorServiceIngress); - $clientConnectorServiceEgress = new Egress(); - $clientConnectorService->setEgress($clientConnectorServiceEgress); - $response = $gapicClient->createClientConnectorService($formattedParent, $clientConnectorService); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/CreateClientConnectorService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getClientConnectorService(); - $this->assertProtobufEquals($clientConnectorService, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClientConnectorServiceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createClientConnectorServiceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $clientConnectorService = new ClientConnectorService(); - $clientConnectorServiceName = 'clientConnectorServiceName1804966078'; - $clientConnectorService->setName($clientConnectorServiceName); - $clientConnectorServiceIngress = new Ingress(); - $clientConnectorService->setIngress($clientConnectorServiceIngress); - $clientConnectorServiceEgress = new Egress(); - $clientConnectorService->setEgress($clientConnectorServiceEgress); - $response = $gapicClient->createClientConnectorService($formattedParent, $clientConnectorService); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClientConnectorServiceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteClientConnectorServiceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteClientConnectorServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - $response = $gapicClient->deleteClientConnectorService($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/DeleteClientConnectorService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClientConnectorServiceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteClientConnectorServiceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - $response = $gapicClient->deleteClientConnectorService($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClientConnectorServiceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getClientConnectorServiceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new ClientConnectorService(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - $response = $gapicClient->getClientConnectorService($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/GetClientConnectorService', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getClientConnectorServiceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->clientConnectorServiceName('[PROJECT]', '[LOCATION]', '[CLIENT_CONNECTOR_SERVICE]'); - try { - $gapicClient->getClientConnectorService($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listClientConnectorServicesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $clientConnectorServicesElement = new ClientConnectorService(); - $clientConnectorServices = [ - $clientConnectorServicesElement, - ]; - $expectedResponse = new ListClientConnectorServicesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setClientConnectorServices($clientConnectorServices); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listClientConnectorServices($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getClientConnectorServices()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/ListClientConnectorServices', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listClientConnectorServicesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listClientConnectorServices($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateClientConnectorServiceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new ClientConnectorService(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateClientConnectorServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $clientConnectorService = new ClientConnectorService(); - $clientConnectorServiceName = 'clientConnectorServiceName1804966078'; - $clientConnectorService->setName($clientConnectorServiceName); - $clientConnectorServiceIngress = new Ingress(); - $clientConnectorService->setIngress($clientConnectorServiceIngress); - $clientConnectorServiceEgress = new Egress(); - $clientConnectorService->setEgress($clientConnectorServiceEgress); - $response = $gapicClient->updateClientConnectorService($updateMask, $clientConnectorService); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorServicesService/UpdateClientConnectorService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getClientConnectorService(); - $this->assertProtobufEquals($clientConnectorService, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateClientConnectorServiceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateClientConnectorServiceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateClientConnectorServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $clientConnectorService = new ClientConnectorService(); - $clientConnectorServiceName = 'clientConnectorServiceName1804966078'; - $clientConnectorService->setName($clientConnectorServiceName); - $clientConnectorServiceIngress = new Ingress(); - $clientConnectorService->setIngress($clientConnectorServiceIngress); - $clientConnectorServiceEgress = new Egress(); - $clientConnectorService->setEgress($clientConnectorServiceEgress); - $response = $gapicClient->updateClientConnectorService($updateMask, $clientConnectorService); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateClientConnectorServiceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientgateways/V1/ClientGatewaysService.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/GPBMetadata/Google/Cloud/Beyondcorp/Clientgateways/V1/ClientGatewaysService.php deleted file mode 100644 index 2a47a41148836e03886189b035bb660ad612aea6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4281 zcmb_f&2QX96ld2-noMY$x=OoQL^0cKIX zJx&PGUbt~ULgLH~aX|b7`~^rk(pyg)5QpB85E2q^JY(;AvnAPtT(X{-_vXFdd+#^z zeelrR_0VmpiXH451h=H-p+t7E4aC7>#PAzEPs;8^uIDEcB~yJYBhukZBu1AhDe)zj%vXf{u^` ze_q(MEmI1JLEzsVE6^>+B9>uWUjPPcQroZt44O`!ZHJCYEZ32!z@}s3g++}ih}C|s@n6Zr{YzD4BpXX9$DCK74fdI zZ@K{Z| zC9{x(fCgk9{W*uK|5L4qi%gLm6`kBGI#}qh3VDAef0N&7cor`}R&V*Y`Zn4$K6;Y} zh##2iJK*yu@U7c?%kDv~xCzt)7ewU^wV;p~Pj;a2kAN<%hgQwJ=MrqO8@*jmHiN;yWnEqNJOy<6sjQA!fqdL~^X~42?%x#94H0Yg^l{ z=sO!*wMuFI(R!sk^P2cNnk>~T+V=WJbtXfBEr%&EdpdNWNX%WM zX=89mSePn&jBZwO8rm4ywN#mLT+f~Wg|D(GUy6z{6}edb#RGQ>T}y+fLk&f~vHcilKO*D_WOgS<)^_YAzcf+n%k8i|UbrikG~yVEN)ffD^b_M1J7 z1@R4Zg_3U==81hgmu*LU6H#X5wIJruG%%J9iUWA@bC=@y z39G+MqS+K40dEV%KQc%>S;b;`gd#mD&I=)5xu6zCC56(L&wu|mdrw@YP4p4t#I=Nj zm-@JOX^?YYXq-dE=NU9J$OmF^1Oo?!V<*qeX9X?g7k&6&;nmUC2F{JeNJ7o3`uk6@SX2WoU`w#5lb*EarzYPmNB9wah0wOau3g zHd`I{KgMXVEt#a_LE3BHXDQQL_%XX!jRt4AM9r7k;9P>a92V$^5I1G=)0N}+Y=ckP ze9We&=~Dmk1`OISv&&4ksz%CHwWpmf^`BSOrz_0~;40$2JD&_hci9BnH}F#Cx6C2K NZgi3jrCroT=wGLfu{Hnz diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway.php deleted file mode 100644 index 720bc7d33494..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway.php +++ /dev/null @@ -1,265 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.ClientGateway - */ -class ClientGateway extends \Google\Protobuf\Internal\Message -{ - /** - * Required. name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The operational state of the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. A unique identifier for the instance generated by the system. - * - * Generated from protobuf field string id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $id = ''; - /** - * Output only. The client connector service name that the client gateway is - * associated to. Client Connector Services, named as follows: - * `projects/{project_id}/locations/{location_id}/client_connector_services/{client_connector_service_id}`. - * - * Generated from protobuf field string client_connector_service = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $client_connector_service = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. name of resource. The name is ignored during creation. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. [Output only] Create time stamp. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. [Output only] Update time stamp. - * @type int $state - * Output only. The operational state of the gateway. - * @type string $id - * Output only. A unique identifier for the instance generated by the system. - * @type string $client_connector_service - * Output only. The client connector service name that the client gateway is - * associated to. Client Connector Services, named as follows: - * `projects/{project_id}/locations/{location_id}/client_connector_services/{client_connector_service_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. name of resource. The name is ignored during creation. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. [Output only] Update time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The operational state of the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The operational state of the gateway. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. A unique identifier for the instance generated by the system. - * - * Generated from protobuf field string id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Output only. A unique identifier for the instance generated by the system. - * - * Generated from protobuf field string id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Output only. The client connector service name that the client gateway is - * associated to. Client Connector Services, named as follows: - * `projects/{project_id}/locations/{location_id}/client_connector_services/{client_connector_service_id}`. - * - * Generated from protobuf field string client_connector_service = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getClientConnectorService() - { - return $this->client_connector_service; - } - - /** - * Output only. The client connector service name that the client gateway is - * associated to. Client Connector Services, named as follows: - * `projects/{project_id}/locations/{location_id}/client_connector_services/{client_connector_service_id}`. - * - * Generated from protobuf field string client_connector_service = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setClientConnectorService($var) - { - GPBUtil::checkString($var, True); - $this->client_connector_service = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway/State.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway/State.php deleted file mode 100644 index f22273017c96..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway/State.php +++ /dev/null @@ -1,93 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.ClientGateway.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Gateway is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * Gateway is being updated. - * - * Generated from protobuf enum UPDATING = 2; - */ - const UPDATING = 2; - /** - * Gateway is being deleted. - * - * Generated from protobuf enum DELETING = 3; - */ - const DELETING = 3; - /** - * Gateway is running. - * - * Generated from protobuf enum RUNNING = 4; - */ - const RUNNING = 4; - /** - * Gateway is down and may be restored in the future. - * This happens when CCFE sends ProjectState = OFF. - * - * Generated from protobuf enum DOWN = 5; - */ - const DOWN = 5; - /** - * ClientGateway encountered an error and is in indeterministic state. - * - * Generated from protobuf enum ERROR = 6; - */ - const ERROR = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::RUNNING => 'RUNNING', - self::DOWN => 'DOWN', - self::ERROR => 'ERROR', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway_State::class); - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGatewayOperationMetadata.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGatewayOperationMetadata.php deleted file mode 100644 index eebce8959553..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGatewayOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.ClientGatewayOperationMetadata - */ -class ClientGatewayOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have been cancelled successfully - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have been cancelled successfully - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have been cancelled successfully - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have been cancelled successfully - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway_State.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway_State.php deleted file mode 100644 index d7617e903ec8..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ClientGateway_State.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/ListClientGateways', - $argument, - ['\Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single ClientGateway. - * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\GetClientGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetClientGateway(\Google\Cloud\BeyondCorp\ClientGateways\V1\GetClientGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/GetClientGateway', - $argument, - ['\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway', 'decode'], - $metadata, $options); - } - - /** - * Creates a new ClientGateway in a given project and location. - * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\CreateClientGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateClientGateway(\Google\Cloud\BeyondCorp\ClientGateways\V1\CreateClientGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/CreateClientGateway', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single ClientGateway. - * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\DeleteClientGatewayRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteClientGateway(\Google\Cloud\BeyondCorp\ClientGateways\V1\DeleteClientGatewayRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/DeleteClientGateway', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/CreateClientGatewayRequest.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/CreateClientGatewayRequest.php deleted file mode 100644 index 09b409646d7a..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/CreateClientGatewayRequest.php +++ /dev/null @@ -1,290 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.CreateClientGatewayRequest - */ -class CreateClientGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string client_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $client_gateway_id = ''; - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $client_gateway = null; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. Value for parent. Please see - * {@see ClientGatewaysServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $clientGateway Required. The resource being created. - * @param string $clientGatewayId Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\CreateClientGatewayRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $clientGateway, string $clientGatewayId): self - { - return (new self()) - ->setParent($parent) - ->setClientGateway($clientGateway) - ->setClientGatewayId($clientGatewayId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Value for parent. - * @type string $client_gateway_id - * Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $client_gateway - * Required. The resource being created. - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Value for parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string client_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getClientGatewayId() - { - return $this->client_gateway_id; - } - - /** - * Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * - * Generated from protobuf field string client_gateway_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setClientGatewayId($var) - { - GPBUtil::checkString($var, True); - $this->client_gateway_id = $var; - - return $this; - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway|null - */ - public function getClientGateway() - { - return $this->client_gateway; - } - - public function hasClientGateway() - { - return isset($this->client_gateway); - } - - public function clearClientGateway() - { - unset($this->client_gateway); - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateway = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway $var - * @return $this - */ - public function setClientGateway($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway::class); - $this->client_gateway = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/DeleteClientGatewayRequest.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/DeleteClientGatewayRequest.php deleted file mode 100644 index 4ebd3346210c..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/DeleteClientGatewayRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.DeleteClientGatewayRequest - */ -class DeleteClientGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $name Required. Name of the resource - * Please see {@see ClientGatewaysServiceClient::clientGatewayName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\DeleteClientGatewayRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource - * @type string $request_id - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validate_only - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * - * Generated from protobuf field string request_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/GetClientGatewayRequest.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/GetClientGatewayRequest.php deleted file mode 100644 index 34aa28bf8694..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/GetClientGatewayRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.GetClientGatewayRequest - */ -class GetClientGatewayRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource - * Please see {@see ClientGatewaysServiceClient::clientGatewayName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\GetClientGatewayRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysRequest.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysRequest.php deleted file mode 100644 index 4c7efdb4e0d1..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.ListClientGatewaysRequest - */ -class ListClientGatewaysRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListClientGatewaysRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Parent value for ListClientGatewaysRequest. Please see - * {@see ClientGatewaysServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Parent value for ListClientGatewaysRequest. - * @type int $page_size - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * @type string $page_token - * Optional. A token identifying a page of results the server should return. - * @type string $filter - * Optional. Filtering results. - * @type string $order_by - * Optional. Hint for how to order the results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListClientGatewaysRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent value for ListClientGatewaysRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. Requested page size. Server may return fewer items than - * requested. If unspecified, server will pick an appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Filtering results. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysResponse.php b/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysResponse.php deleted file mode 100644 index 41559467cdc4..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/proto/src/Google/Cloud/BeyondCorp/ClientGateways/V1/ListClientGatewaysResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.beyondcorp.clientgateways.v1.ListClientGatewaysResponse - */ -class ListClientGatewaysResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of ClientGateway. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateways = 1; - */ - private $client_gateways; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway>|\Google\Protobuf\Internal\RepeatedField $client_gateways - * The list of ClientGateway. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Beyondcorp\Clientgateways\V1\ClientGatewaysService::initOnce(); - parent::__construct($data); - } - - /** - * The list of ClientGateway. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateways = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getClientGateways() - { - return $this->client_gateways; - } - - /** - * The list of ClientGateway. - * - * Generated from protobuf field repeated .google.cloud.beyondcorp.clientgateways.v1.ClientGateway client_gateways = 1; - * @param array<\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setClientGateways($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway::class); - $this->client_gateways = $arr; - - return $this; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php deleted file mode 100644 index f145f557fcb2..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/create_client_gateway.php +++ /dev/null @@ -1,88 +0,0 @@ -setName($clientGatewayName); - $request = (new CreateClientGatewayRequest()) - ->setParent($formattedParent) - ->setClientGateway($clientGateway); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $clientGatewaysServiceClient->createClientGateway($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ClientGateway $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 = ClientGatewaysServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $clientGatewayName = '[NAME]'; - - create_client_gateway_sample($formattedParent, $clientGatewayName); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_CreateClientGateway_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php deleted file mode 100644 index 5e6d831dbdf5..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/delete_client_gateway.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $clientGatewaysServiceClient->deleteClientGateway($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 = ClientGatewaysServiceClient::clientGatewayName( - '[PROJECT]', - '[LOCATION]', - '[CLIENT_GATEWAY]' - ); - - delete_client_gateway_sample($formattedName); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_DeleteClientGateway_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php deleted file mode 100644 index 1804dd565d5d..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_client_gateway.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ClientGateway $response */ - $response = $clientGatewaysServiceClient->getClientGateway($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 = ClientGatewaysServiceClient::clientGatewayName( - '[PROJECT]', - '[LOCATION]', - '[CLIENT_GATEWAY]' - ); - - get_client_gateway_sample($formattedName); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_GetClientGateway_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php deleted file mode 100644 index 496f36cee39b..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $clientGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_location.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_location.php deleted file mode 100644 index c3b156f05bcc..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_ClientGatewaysService_GetLocation_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php deleted file mode 100644 index c7d623a82b74..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_client_gateways.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $clientGatewaysServiceClient->listClientGateways($request); - - /** @var ClientGateway $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 = ClientGatewaysServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_client_gateways_sample($formattedParent); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_ListClientGateways_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_locations.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_locations.php deleted file mode 100644 index 2942bdfcb69e..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END beyondcorp_v1_generated_ClientGatewaysService_ListLocations_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php deleted file mode 100644 index 1ce708a03424..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $clientGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php b/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php deleted file mode 100644 index 25dc5418e072..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/samples/V1/ClientGatewaysServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $clientGatewaysServiceClient->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); -} -// [END beyondcorp_v1_generated_ClientGatewaysService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/ClientGatewaysServiceClient.php b/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/ClientGatewaysServiceClient.php deleted file mode 100644 index a6c53b4b2a8f..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/ClientGatewaysServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $clientGateway = new ClientGateway(); - * $operationResponse = $clientGatewaysServiceClient->createClientGateway($formattedParent, $clientGateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientGatewaysServiceClient->createClientGateway($formattedParent, $clientGateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientGatewaysServiceClient->resumeOperation($operationName, 'createClientGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * 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. - */ -class ClientGatewaysServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'beyondcorp.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $clientGatewayNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/client_gateways_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/client_gateways_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/client_gateways_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/client_gateways_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getClientGatewayNameTemplate() - { - if (self::$clientGatewayNameTemplate == null) { - self::$clientGatewayNameTemplate = new PathTemplate('projects/{project}/locations/{location}/clientGateways/{client_gateway}'); - } - - return self::$clientGatewayNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'clientGateway' => self::getClientGatewayNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * client_gateway resource. - * - * @param string $project - * @param string $location - * @param string $clientGateway - * - * @return string The formatted client_gateway resource. - */ - public static function clientGatewayName($project, $location, $clientGateway) - { - return self::getClientGatewayNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'client_gateway' => $clientGateway, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - clientGateway: projects/{project}/locations/{location}/clientGateways/{client_gateway} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'beyondcorp.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new ClientGateway in a given project and location. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $formattedParent = $clientGatewaysServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $clientGateway = new ClientGateway(); - * $operationResponse = $clientGatewaysServiceClient->createClientGateway($formattedParent, $clientGateway); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientGatewaysServiceClient->createClientGateway($formattedParent, $clientGateway); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientGatewaysServiceClient->resumeOperation($operationName, 'createClientGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Value for parent. - * @param ClientGateway $clientGateway Required. The resource being created. - * @param array $optionalArgs { - * Optional. - * - * @type string $clientGatewayId - * Optional. User-settable client gateway resource ID. - * * Must start with a letter. - * * Must contain between 4-63 characters from `/[a-z][0-9]-/`. - * * Must end with a number or a letter. - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes since the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createClientGateway($parent, $clientGateway, array $optionalArgs = []) - { - $request = new CreateClientGatewayRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setClientGateway($clientGateway); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['clientGatewayId'])) { - $request->setClientGatewayId($optionalArgs['clientGatewayId']); - } - - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateClientGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single ClientGateway. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $formattedName = $clientGatewaysServiceClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - * $operationResponse = $clientGatewaysServiceClient->deleteClientGateway($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $clientGatewaysServiceClient->deleteClientGateway($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $clientGatewaysServiceClient->resumeOperation($operationName, 'deleteClientGateway'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * Optional. An optional request ID to identify requests. Specify a unique - * request ID so that if you must retry your request, the server will know to - * ignore the request if it has already been completed. The server will - * guarantee that for at least 60 minutes after the first request. - * - * For example, consider a situation where you make an initial request and t - * he request times out. If you make the request again with the same request - * ID, the server can check if original operation with the same request ID - * was received, and if so, will ignore the second request. This prevents - * clients from accidentally creating duplicate commitments. - * - * The request ID must be a valid UUID with the exception that zero UUID is - * not supported (00000000-0000-0000-0000-000000000000). - * @type bool $validateOnly - * Optional. If set, validates request by executing a dry-run which would not - * alter the resource in any way. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteClientGateway($name, array $optionalArgs = []) - { - $request = new DeleteClientGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteClientGateway', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single ClientGateway. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $formattedName = $clientGatewaysServiceClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - * $response = $clientGatewaysServiceClient->getClientGateway($formattedName); - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the resource - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway - * - * @throws ApiException if the remote call fails - */ - public function getClientGateway($name, array $optionalArgs = []) - { - $request = new GetClientGatewayRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetClientGateway', ClientGateway::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists ClientGateways in a given project and location. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $formattedParent = $clientGatewaysServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $clientGatewaysServiceClient->listClientGateways($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $clientGatewaysServiceClient->listClientGateways($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Parent value for ListClientGatewaysRequest. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. Filtering results. - * @type string $orderBy - * Optional. Hint for how to order the results. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listClientGateways($parent, array $optionalArgs = []) - { - $request = new ListClientGatewaysRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListClientGateways', $optionalArgs, ListClientGatewaysResponse::class, $request); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $response = $clientGatewaysServiceClient->getLocation(); - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $clientGatewaysServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $clientGatewaysServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $response = $clientGatewaysServiceClient->getIamPolicy($resource); - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $clientGatewaysServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $clientGatewaysServiceClient = new ClientGatewaysServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $clientGatewaysServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $clientGatewaysServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/gapic_metadata.json deleted file mode 100644 index cb3b63e30fc4..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.beyondcorp.clientgateways.v1", - "libraryPackage": "Google\\Cloud\\BeyondCorp\\ClientGateways\\V1", - "services": { - "ClientGatewaysService": { - "clients": { - "grpc": { - "libraryClient": "ClientGatewaysServiceGapicClient", - "rpcs": { - "CreateClientGateway": { - "methods": [ - "createClientGateway" - ] - }, - "DeleteClientGateway": { - "methods": [ - "deleteClientGateway" - ] - }, - "GetClientGateway": { - "methods": [ - "getClientGateway" - ] - }, - "ListClientGateways": { - "methods": [ - "listClientGateways" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_client_config.json b/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_client_config.json deleted file mode 100644 index 582868412a6b..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_client_config.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - "interfaces": { - "google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService": { - "retry_codes": { - "no_retry_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - } - }, - "methods": { - "CreateClientGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "DeleteClientGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetClientGateway": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListClientGateways": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_descriptor_config.php b/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_descriptor_config.php deleted file mode 100644 index 053175b674ef..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_descriptor_config.php +++ /dev/null @@ -1,155 +0,0 @@ - [ - 'google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService' => [ - 'CreateClientGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewayOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteClientGateway' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGatewayOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetClientGateway' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\ClientGateways\V1\ClientGateway', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListClientGateways' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getClientGateways', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BeyondCorp\ClientGateways\V1\ListClientGatewaysResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'clientGateway' => 'projects/{project}/locations/{location}/clientGateways/{client_gateway}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_rest_client_config.php b/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_rest_client_config.php deleted file mode 100644 index eacb5dffb661..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/src/V1/resources/client_gateways_service_rest_client_config.php +++ /dev/null @@ -1,224 +0,0 @@ - [ - 'google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService' => [ - 'CreateClientGateway' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/clientGateways', - 'body' => 'client_gateway', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteClientGateway' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/clientGateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetClientGateway' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/clientGateways/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListClientGateways' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/clientGateways', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnections/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appConnectors/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/appGateways/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientConnectorServices/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/clientGateways/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/ClientGatewaysServiceClientTest.php b/owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/ClientGatewaysServiceClientTest.php deleted file mode 100644 index 5c332f39ff78..000000000000 --- a/owl-bot-staging/BeyondCorpClientGateways/v1/tests/Unit/V1/ClientGatewaysServiceClientTest.php +++ /dev/null @@ -1,761 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ClientGatewaysServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ClientGatewaysServiceClient($options); - } - - /** @test */ - public function createClientGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createClientGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $clientConnectorService = 'clientConnectorService-1152817841'; - $expectedResponse = new ClientGateway(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setClientConnectorService($clientConnectorService); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createClientGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $clientGateway = new ClientGateway(); - $clientGatewayName = 'clientGatewayName-1795593692'; - $clientGateway->setName($clientGatewayName); - $response = $gapicClient->createClientGateway($formattedParent, $clientGateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/CreateClientGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getClientGateway(); - $this->assertProtobufEquals($clientGateway, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClientGatewayTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createClientGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createClientGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $clientGateway = new ClientGateway(); - $clientGatewayName = 'clientGatewayName-1795593692'; - $clientGateway->setName($clientGatewayName); - $response = $gapicClient->createClientGateway($formattedParent, $clientGateway); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClientGatewayTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteClientGatewayTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteClientGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteClientGatewayTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - $response = $gapicClient->deleteClientGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/DeleteClientGateway', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClientGatewayTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteClientGatewayExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteClientGatewayTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - $response = $gapicClient->deleteClientGateway($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClientGatewayTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getClientGatewayTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $clientConnectorService = 'clientConnectorService-1152817841'; - $expectedResponse = new ClientGateway(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setClientConnectorService($clientConnectorService); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - $response = $gapicClient->getClientGateway($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/GetClientGateway', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getClientGatewayExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->clientGatewayName('[PROJECT]', '[LOCATION]', '[CLIENT_GATEWAY]'); - try { - $gapicClient->getClientGateway($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listClientGatewaysTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $clientGatewaysElement = new ClientGateway(); - $clientGateways = [ - $clientGatewaysElement, - ]; - $expectedResponse = new ListClientGatewaysResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setClientGateways($clientGateways); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listClientGateways($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getClientGateways()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.beyondcorp.clientgateways.v1.ClientGatewaysService/ListClientGateways', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listClientGatewaysExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listClientGateways($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Analyticshub/V1/Analyticshub.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Analyticshub/V1/Analyticshub.php deleted file mode 100644 index f43f52abbe139756612079e89562ed40e3647bab..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9700 zcmcgyO>i4Y72c6!Cuup3+|G|;XUSxeu(nC0jk7>9+5C*8v8;;qvy$S?1{bQ4+_s0v zk}@+&;thskYmc1Z##V9QLKO!J4%D7FQ3X|dgsMHHD2f9YQoxDRUf^|4_jpEfoRJLc zDwU<__g=s6{q^hVe)mpivx6?kS<)hw;gB`CzAZbOMDAE^r`>2b<$8C0omg_Cz11SeRyCiz)s?F^5o$CI+m`*$ z(Q_ojU#DAdnhn`@447ZOXxcTiWjdzOG(QBKx8!xBX%i68PrKf2H5{|uk|{&6)gZHT zvMZC)UhK5NF1KW%VTqaw%(R+oIm80}Rx`wISZ2p*TO}Y>)eYi!2BuGD=lHZ#oVhN~ zx;mNrdDXTY*pRGv@7COjOnIH zTFziRizaEVrO2l7#B5uGv6cxBrqD{}j4gPF5es+c$EYPJQ=>Y3W3c*;HEjw`>3pz#dUFa23# z(`aoFJc$m`0vDHLY4&JpBOuN%GwrgxCB8DP3j-qS4dO*6yN5qJP&!XcU z%iJ=o?OLPVa*T!(KeRhKjgGCg8{I9iFH7|JXke^q+K$=U0M2g9iI2h9sH+NSXM(u+ zVR$r7A4#h7QhSVM1AcT(1}?M{un;5z_;j$ucSysrlh66Lon*7!aLY~dx%j%1q*Yy5 z1&Ha-8sS#jQSP{AD_QL)<{Gj3&92u>I=_m=Gv|+BXoeHrURZj5#@&?2=`0Gbu=jiSwcFK7hOmtTrmoiuF- z$&uOUf-a`ozc}mxC9%xp=q<#FEG41~nUH#ONeO66-lJ^}kCzH-g_skT-sq3uFFo;> z&?xOJ2+Qt?g?9!-SE0NV%?QQ9%ES?`OyD9^9Gb!qO)O*MM`0|wa4qB{)MO&rT}PLo zmxBp6+7P>T96=yWEPOMhG~tl6D}aa25<1G7Kw1*wQKsJ8Aq9G+#MNyEO;`jvTHC1^ zjRvvp_&A7TqC zUb|nYl=O6NF{fu@Z(xMRv~)GMqQ@lV(?jTp01b=Bi8PRBi{%e`SfmgeweF-xmC^IXY*{NU<9VFg<_sQ9}7Ou+y|Omu@F0q z{UG#$Ue10HI}#vX%oVgkI;Snijs}RcTAm_7P_3uD8MAt^QUcLH9mTWgqBpRlYs=N8 zv{rWEEaw*WS|y#+3xIkYV>IDW=3x({#g5@=bjo{Hx}RFkrE3*ET`iVl69GNSdR5CU z$BqXcR!YTkwGxZr^XN@a3ZIYJv#eKit(;zpP2xFp$s?(jHHZq}W#(a&%f)Q2Ql&=3 z_#B$?ldkB?jHFt;U(QwXu_^T<>8194bYZ`BUKGp+e2F{Q5}$0k^%tb@Z#$_YXv}T- zmG7cBosO0TuSqDoDTi;Mv5o-?vBOv1IauYs&@Q0!Vqvg*Q)!tuAW*oDc8m>DvtiT6 zmV;67AYzZ4_9MbOEae9hIdv zwGB!Q%}^DJ*2bPjfTpo+Z5S={L$|^6`pHOGkRMCv?A|kcsW=~?Q&|#lwD9xoK&$*V z^YVQ7R#f>tcrk4eSOfeP6w(h6MQ@^5AOM2Bp0^Z=_+V}OaN)t42jyn~Ln-whI^l+U zk4^{h&~GJly3(!FmxXoGBlZEBf)@c|L+b5Q=nH}9!i|tI*S}SSeaY|&r;f4xp-@Vh zM)7|2-9%aV%M6lI=>F<~eDLPC=is=q?p_)bVbeVjZ`rtc0fz*SgDee|cl z{Wx+BU!`x9p1b|VEwAyJ_r24Y?|GN;LgVcT{x<|JRk3#s$6@#Odoc@$=>Z`2DgbX* zSu3Md7|PrDU53)%P~7tWu#@`(4zwcp4-z`wv!vr&A+_z{6JUpFt(3a~7t&X2uW(?` zyQuk{7aDs>hyNkLo}{mXz+t1SpY=d^Y79?G89XFacW*8lk{8+uH=r*E+8F#FfZN|^ zgofMCdLXzKgIij-!(ua_X<`s(_JKbWkagMDJmFt~1^T;~&=%-t6&5%p;@|7X*l~e~ z(RtUWgTN9o`niP0X`P@S+8be2OckO75llkOn?v#PVv-LOlYL8OU&eX6!QJZlI|-rP z4hUZlsoE}!05#zHuG|aY7{DhUh~#bw`Ll$M1==ng*2V#@VX=IhVaY0PfgjQ*s_5cg zXcN3}G~H;!e+PJh-Yhh{0N1ea9x-^ug$%0^T&Y2-gWqL7m{VL-pg8;*um*a*&{zXp z0_&?v0uR4=*JTF`zkf<7*4vcf+aXh_mr-aQwms|T=au3CbK5;-k-2S1h^j4mWmTFN z)$m_X4WR;fC%{+{Sm9I<4j>c$L4oIF4~=^Y4BKv|<|mSpVtR^G$FN-lJ?Qro0UaNf zmHaS*0x{Yn6H~wy-#mSQ{e%B+!0@{Ie-5}uCjLnT;VNu}=tRWYGHsh)WWcjMKI|tE z;O9b6@;Lpa8v#F;l%-)Dx1&0JiqbfEpj3tt7l?yBB~L&5Oq~=vMjV zB6_=s9pkO;UN3?j>nhwVc^R2=WvVI@s;WTCZZ@f^U#zMEt+w>qvmJcN+fnYGmecMO of}Wp=!?&IK80#9Zz2#llxa?j8^4%MH<((l$>E7+xK|2Wj7g*@rsQ>@~ diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/AnalyticsHubServiceGrpcClient.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/AnalyticsHubServiceGrpcClient.php deleted file mode 100644 index 23a90e520539..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/AnalyticsHubServiceGrpcClient.php +++ /dev/null @@ -1,271 +0,0 @@ -_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListDataExchanges', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesResponse', 'decode'], - $metadata, $options); - } - - /** - * Lists all data exchanges from projects in a given organization and - * location. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListOrgDataExchanges(\Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListOrgDataExchanges', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of a data exchange. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\GetDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetDataExchange(\Google\Cloud\BigQuery\AnalyticsHub\V1\GetDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetDataExchange', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Creates a new data exchange. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateDataExchange(\Google\Cloud\BigQuery\AnalyticsHub\V1\CreateDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/CreateDataExchange', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Updates an existing data exchange. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateDataExchange(\Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/UpdateDataExchange', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Deletes an existing data exchange. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteDataExchange(\Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/DeleteDataExchange', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Lists all listings in a given project and location. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListListings(\Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListListings', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of a listing. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\GetListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetListing(\Google\Cloud\BigQuery\AnalyticsHub\V1\GetListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetListing', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Creates a new listing. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateListing(\Google\Cloud\BigQuery\AnalyticsHub\V1\CreateListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/CreateListing', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Updates an existing listing. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateListing(\Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/UpdateListing', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Deletes a listing. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteListing(\Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/DeleteListing', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Subscribes to a listing. - * - * Currently, with Analytics Hub, you can create listings that - * reference only BigQuery datasets. - * Upon subscription to a listing for a BigQuery dataset, Analytics Hub - * creates a linked dataset in the subscriber's project. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SubscribeListing(\Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/SubscribeListing', - $argument, - ['\Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the IAM policy. - * @param \Google\Cloud\Iam\V1\GetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetIamPolicy(\Google\Cloud\Iam\V1\GetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Sets the IAM policy. - * @param \Google\Cloud\Iam\V1\SetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SetIamPolicy(\Google\Cloud\Iam\V1\SetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/SetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Returns the permissions that a caller has. - * @param \Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TestIamPermissions(\Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/TestIamPermissions', - $argument, - ['\Google\Cloud\Iam\V1\TestIamPermissionsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateDataExchangeRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateDataExchangeRequest.php deleted file mode 100644 index b5c50a9432c0..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateDataExchangeRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.CreateDataExchangeRequest - */ -class CreateDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange_id = ''; - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange = null; - - /** - * @param string $parent Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. Please see - * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange Required. The data exchange to create. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateDataExchangeRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange): self - { - return (new self()) - ->setParent($parent) - ->setDataExchange($dataExchange); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * @type string $data_exchange_id - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $data_exchange - * Required. The data exchange to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDataExchangeId() - { - return $this->data_exchange_id; - } - - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDataExchangeId($var) - { - GPBUtil::checkString($var, True); - $this->data_exchange_id = $var; - - return $this; - } - - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange|null - */ - public function getDataExchange() - { - return $this->data_exchange; - } - - public function hasDataExchange() - { - return isset($this->data_exchange); - } - - public function clearDataExchange() - { - unset($this->data_exchange); - } - - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $var - * @return $this - */ - public function setDataExchange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange::class); - $this->data_exchange = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateListingRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateListingRequest.php deleted file mode 100644 index e7fe7aa5bd6c..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/CreateListingRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.CreateListingRequest - */ -class CreateListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing_id = ''; - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing = null; - - /** - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing Required. The listing to create. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\CreateListingRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing): self - { - return (new self()) - ->setParent($parent) - ->setListing($listing); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type string $listing_id - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing - * Required. The listing to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getListingId() - { - return $this->listing_id; - } - - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setListingId($var) - { - GPBUtil::checkString($var, True); - $this->listing_id = $var; - - return $this; - } - - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing|null - */ - public function getListing() - { - return $this->listing; - } - - public function hasListing() - { - return isset($this->listing); - } - - public function clearListing() - { - unset($this->listing); - } - - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $var - * @return $this - */ - public function setListing($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing::class); - $this->listing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataExchange.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataExchange.php deleted file mode 100644 index 3e9e560d6e6d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataExchange.php +++ /dev/null @@ -1,329 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DataExchange - */ -class DataExchange extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $display_name = ''; - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $documentation = ''; - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $listing_count = 0; - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $icon = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type string $display_name - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * @type string $description - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * @type string $primary_contact - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * @type string $documentation - * Optional. Documentation describing the data exchange. - * @type int $listing_count - * Output only. Number of listings contained in the data exchange. - * @type string $icon - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDocumentation() - { - return $this->documentation; - } - - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDocumentation($var) - { - GPBUtil::checkString($var, True); - $this->documentation = $var; - - return $this; - } - - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getListingCount() - { - return $this->listing_count; - } - - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setListingCount($var) - { - GPBUtil::checkInt32($var); - $this->listing_count = $var; - - return $this; - } - - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getIcon() - { - return $this->icon; - } - - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setIcon($var) - { - GPBUtil::checkString($var, False); - $this->icon = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataProvider.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataProvider.php deleted file mode 100644 index ae0efbfc4a0e..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DataProvider.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DataProvider - */ -class DataProvider extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name = ''; - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Optional. Name of the data provider. - * @type string $primary_contact - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteDataExchangeRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteDataExchangeRequest.php deleted file mode 100644 index 019d7715863d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteDataExchangeRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DeleteDataExchangeRequest - */ -class DeleteDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteDataExchangeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteListingRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteListingRequest.php deleted file mode 100644 index 630e70a33f4e..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DeleteListingRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DeleteListingRequest - */ -class DeleteListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DeleteListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDataset.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDataset.php deleted file mode 100644 index 05c16ab5c7e9..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDataset.php +++ /dev/null @@ -1,311 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DestinationDataset - */ -class DestinationDataset extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dataset_reference = null; - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $friendly_name = null; - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = null; - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $location = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDatasetReference $dataset_reference - * Required. A reference that identifies the destination dataset. - * @type \Google\Protobuf\StringValue $friendly_name - * Optional. A descriptive name for the dataset. - * @type \Google\Protobuf\StringValue $description - * Optional. A user-friendly description of the dataset. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * @type string $location - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDatasetReference|null - */ - public function getDatasetReference() - { - return $this->dataset_reference; - } - - public function hasDatasetReference() - { - return isset($this->dataset_reference); - } - - public function clearDatasetReference() - { - unset($this->dataset_reference); - } - - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDatasetReference $var - * @return $this - */ - public function setDatasetReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDatasetReference::class); - $this->dataset_reference = $var; - - return $this; - } - - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\StringValue|null - */ - public function getFriendlyName() - { - return $this->friendly_name; - } - - public function hasFriendlyName() - { - return isset($this->friendly_name); - } - - public function clearFriendlyName() - { - unset($this->friendly_name); - } - - /** - * Returns the unboxed value from getFriendlyName() - - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string|null - */ - public function getFriendlyNameUnwrapped() - { - return $this->readWrapperValue("friendly_name"); - } - - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\StringValue $var - * @return $this - */ - public function setFriendlyName($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class); - $this->friendly_name = $var; - - return $this; - } - - /** - * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object. - - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string|null $var - * @return $this - */ - public function setFriendlyNameUnwrapped($var) - { - $this->writeWrapperValue("friendly_name", $var); - return $this;} - - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\StringValue|null - */ - public function getDescription() - { - return $this->description; - } - - public function hasDescription() - { - return isset($this->description); - } - - public function clearDescription() - { - unset($this->description); - } - - /** - * Returns the unboxed value from getDescription() - - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string|null - */ - public function getDescriptionUnwrapped() - { - return $this->readWrapperValue("description"); - } - - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\StringValue $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class); - $this->description = $var; - - return $this; - } - - /** - * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object. - - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string|null $var - * @return $this - */ - public function setDescriptionUnwrapped($var) - { - $this->writeWrapperValue("description", $var); - return $this;} - - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDatasetReference.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDatasetReference.php deleted file mode 100644 index 0158d1b6c937..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/DestinationDatasetReference.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.DestinationDatasetReference - */ -class DestinationDatasetReference extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dataset_id = ''; - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dataset_id - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * @type string $project_id - * Required. The ID of the project containing this dataset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDatasetId() - { - return $this->dataset_id; - } - - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDatasetId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id = $var; - - return $this; - } - - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetDataExchangeRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetDataExchangeRequest.php deleted file mode 100644 index ac579385d217..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetDataExchangeRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.GetDataExchangeRequest - */ -class GetDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\GetDataExchangeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetListingRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetListingRequest.php deleted file mode 100644 index a8e2c2523961..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/GetListingRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.GetListingRequest - */ -class GetListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\GetListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesRequest.php deleted file mode 100644 index fe9ae5f2f822..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListDataExchangesRequest - */ -class ListDataExchangesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. Please see - * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesResponse.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesResponse.php deleted file mode 100644 index fb8bbdccd266..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListDataExchangesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListDataExchangesResponse - */ -class ListDataExchangesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - */ - private $data_exchanges; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $data_exchanges - * The list of data exchanges. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataExchanges() - { - return $this->data_exchanges; - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - * @param array<\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataExchanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange::class); - $this->data_exchanges = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsRequest.php deleted file mode 100644 index acff05320794..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListListingsRequest - */ -class ListListingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsResponse.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsResponse.php deleted file mode 100644 index 2a35739b95ea..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListListingsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListListingsResponse - */ -class ListListingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing listings = 1; - */ - private $listings; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing>|\Google\Protobuf\Internal\RepeatedField $listings - * The list of Listing. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing listings = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListings() - { - return $this->listings; - } - - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing listings = 1; - * @param array<\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing::class); - $this->listings = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesRequest.php deleted file mode 100644 index 7417f24eea66..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListOrgDataExchangesRequest - */ -class ListOrgDataExchangesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $organization = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $organization Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesRequest - * - * @experimental - */ - public static function build(string $organization): self - { - return (new self()) - ->setOrganization($organization); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $organization - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getOrganization() - { - return $this->organization; - } - - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setOrganization($var) - { - GPBUtil::checkString($var, True); - $this->organization = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesResponse.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesResponse.php deleted file mode 100644 index d33782786693..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/ListOrgDataExchangesResponse.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.ListOrgDataExchangesResponse - */ -class ListOrgDataExchangesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - */ - private $data_exchanges; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $data_exchanges - * The list of data exchanges. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataExchanges() - { - return $this->data_exchanges; - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchanges = 1; - * @param array<\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataExchanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange::class); - $this->data_exchanges = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing.php deleted file mode 100644 index 7aef9e99c326..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing.php +++ /dev/null @@ -1,540 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.Listing - */ -class Listing extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $display_name = ''; - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $documentation = ''; - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $icon = ''; - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $data_provider = null; - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $categories; - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $publisher = null; - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_access = ''; - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource $bigquery_dataset - * Required. Shared dataset i.e. BigQuery dataset source. - * @type string $name - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * @type string $display_name - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * @type string $description - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * @type string $primary_contact - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * @type string $documentation - * Optional. Documentation describing the listing. - * @type int $state - * Output only. Current state of the listing. - * @type string $icon - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\DataProvider $data_provider - * Optional. Details of the data provider who owns the source data. - * @type array|\Google\Protobuf\Internal\RepeatedField $categories - * Optional. Categories of the listing. Up to two categories are allowed. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\Publisher $publisher - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * @type string $request_access - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. Shared dataset i.e. BigQuery dataset source. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing.BigQueryDatasetSource bigquery_dataset = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource|null - */ - public function getBigqueryDataset() - { - return $this->readOneof(6); - } - - public function hasBigqueryDataset() - { - return $this->hasOneof(6); - } - - /** - * Required. Shared dataset i.e. BigQuery dataset source. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing.BigQueryDatasetSource bigquery_dataset = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource $var - * @return $this - */ - public function setBigqueryDataset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\BigQueryDatasetSource::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDocumentation() - { - return $this->documentation; - } - - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDocumentation($var) - { - GPBUtil::checkString($var, True); - $this->documentation = $var; - - return $this; - } - - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\State::class); - $this->state = $var; - - return $this; - } - - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getIcon() - { - return $this->icon; - } - - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setIcon($var) - { - GPBUtil::checkString($var, False); - $this->icon = $var; - - return $this; - } - - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataProvider|null - */ - public function getDataProvider() - { - return $this->data_provider; - } - - public function hasDataProvider() - { - return isset($this->data_provider); - } - - public function clearDataProvider() - { - unset($this->data_provider); - } - - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataProvider $var - * @return $this - */ - public function setDataProvider($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataProvider::class); - $this->data_provider = $var; - - return $this; - } - - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCategories() - { - return $this->categories; - } - - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.analyticshub.v1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCategories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing\Category::class); - $this->categories = $arr; - - return $this; - } - - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Publisher|null - */ - public function getPublisher() - { - return $this->publisher; - } - - public function hasPublisher() - { - return isset($this->publisher); - } - - public function clearPublisher() - { - unset($this->publisher); - } - - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Publisher $var - * @return $this - */ - public function setPublisher($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\Publisher::class); - $this->publisher = $var; - - return $this; - } - - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestAccess() - { - return $this->request_access; - } - - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestAccess($var) - { - GPBUtil::checkString($var, True); - $this->request_access = $var; - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/BigQueryDatasetSource.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/BigQueryDatasetSource.php deleted file mode 100644 index cef6f8558c68..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/BigQueryDatasetSource.php +++ /dev/null @@ -1,80 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.Listing.BigQueryDatasetSource - */ -class BigQueryDatasetSource extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - */ - protected $dataset = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dataset - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getDataset() - { - return $this->dataset; - } - - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setDataset($var) - { - GPBUtil::checkString($var, True); - $this->dataset = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(BigQueryDatasetSource::class, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing_BigQueryDatasetSource::class); - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/Category.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/Category.php deleted file mode 100644 index c16d7e7d770d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/Category.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.Listing.Category - */ -class Category -{ - /** - * Generated from protobuf enum CATEGORY_UNSPECIFIED = 0; - */ - const CATEGORY_UNSPECIFIED = 0; - /** - * Generated from protobuf enum CATEGORY_OTHERS = 1; - */ - const CATEGORY_OTHERS = 1; - /** - * Generated from protobuf enum CATEGORY_ADVERTISING_AND_MARKETING = 2; - */ - const CATEGORY_ADVERTISING_AND_MARKETING = 2; - /** - * Generated from protobuf enum CATEGORY_COMMERCE = 3; - */ - const CATEGORY_COMMERCE = 3; - /** - * Generated from protobuf enum CATEGORY_CLIMATE_AND_ENVIRONMENT = 4; - */ - const CATEGORY_CLIMATE_AND_ENVIRONMENT = 4; - /** - * Generated from protobuf enum CATEGORY_DEMOGRAPHICS = 5; - */ - const CATEGORY_DEMOGRAPHICS = 5; - /** - * Generated from protobuf enum CATEGORY_ECONOMICS = 6; - */ - const CATEGORY_ECONOMICS = 6; - /** - * Generated from protobuf enum CATEGORY_EDUCATION = 7; - */ - const CATEGORY_EDUCATION = 7; - /** - * Generated from protobuf enum CATEGORY_ENERGY = 8; - */ - const CATEGORY_ENERGY = 8; - /** - * Generated from protobuf enum CATEGORY_FINANCIAL = 9; - */ - const CATEGORY_FINANCIAL = 9; - /** - * Generated from protobuf enum CATEGORY_GAMING = 10; - */ - const CATEGORY_GAMING = 10; - /** - * Generated from protobuf enum CATEGORY_GEOSPATIAL = 11; - */ - const CATEGORY_GEOSPATIAL = 11; - /** - * Generated from protobuf enum CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE = 12; - */ - const CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE = 12; - /** - * Generated from protobuf enum CATEGORY_MEDIA = 13; - */ - const CATEGORY_MEDIA = 13; - /** - * Generated from protobuf enum CATEGORY_PUBLIC_SECTOR = 14; - */ - const CATEGORY_PUBLIC_SECTOR = 14; - /** - * Generated from protobuf enum CATEGORY_RETAIL = 15; - */ - const CATEGORY_RETAIL = 15; - /** - * Generated from protobuf enum CATEGORY_SPORTS = 16; - */ - const CATEGORY_SPORTS = 16; - /** - * Generated from protobuf enum CATEGORY_SCIENCE_AND_RESEARCH = 17; - */ - const CATEGORY_SCIENCE_AND_RESEARCH = 17; - /** - * Generated from protobuf enum CATEGORY_TRANSPORTATION_AND_LOGISTICS = 18; - */ - const CATEGORY_TRANSPORTATION_AND_LOGISTICS = 18; - /** - * Generated from protobuf enum CATEGORY_TRAVEL_AND_TOURISM = 19; - */ - const CATEGORY_TRAVEL_AND_TOURISM = 19; - - private static $valueToName = [ - self::CATEGORY_UNSPECIFIED => 'CATEGORY_UNSPECIFIED', - self::CATEGORY_OTHERS => 'CATEGORY_OTHERS', - self::CATEGORY_ADVERTISING_AND_MARKETING => 'CATEGORY_ADVERTISING_AND_MARKETING', - self::CATEGORY_COMMERCE => 'CATEGORY_COMMERCE', - self::CATEGORY_CLIMATE_AND_ENVIRONMENT => 'CATEGORY_CLIMATE_AND_ENVIRONMENT', - self::CATEGORY_DEMOGRAPHICS => 'CATEGORY_DEMOGRAPHICS', - self::CATEGORY_ECONOMICS => 'CATEGORY_ECONOMICS', - self::CATEGORY_EDUCATION => 'CATEGORY_EDUCATION', - self::CATEGORY_ENERGY => 'CATEGORY_ENERGY', - self::CATEGORY_FINANCIAL => 'CATEGORY_FINANCIAL', - self::CATEGORY_GAMING => 'CATEGORY_GAMING', - self::CATEGORY_GEOSPATIAL => 'CATEGORY_GEOSPATIAL', - self::CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE => 'CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE', - self::CATEGORY_MEDIA => 'CATEGORY_MEDIA', - self::CATEGORY_PUBLIC_SECTOR => 'CATEGORY_PUBLIC_SECTOR', - self::CATEGORY_RETAIL => 'CATEGORY_RETAIL', - self::CATEGORY_SPORTS => 'CATEGORY_SPORTS', - self::CATEGORY_SCIENCE_AND_RESEARCH => 'CATEGORY_SCIENCE_AND_RESEARCH', - self::CATEGORY_TRANSPORTATION_AND_LOGISTICS => 'CATEGORY_TRANSPORTATION_AND_LOGISTICS', - self::CATEGORY_TRAVEL_AND_TOURISM => 'CATEGORY_TRAVEL_AND_TOURISM', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Category::class, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing_Category::class); - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/State.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/State.php deleted file mode 100644 index 67c97bcd62f1..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing/State.php +++ /dev/null @@ -1,58 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.Listing.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Subscribable state. Users with dataexchange.listings.subscribe permission - * can subscribe to this listing. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing_State::class); - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_BigQueryDatasetSource.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_BigQueryDatasetSource.php deleted file mode 100644 index 7567701fa08d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/Listing_BigQueryDatasetSource.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.Publisher - */ -class Publisher extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name = ''; - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Optional. Name of the listing publisher. - * @type string $primary_contact - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingRequest.php deleted file mode 100644 index c6041fe76652..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingRequest.php +++ /dev/null @@ -1,128 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.SubscribeListingRequest - */ -class SubscribeListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - protected $destination; - - /** - * @param string $name Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDataset $destination_dataset - * BigQuery destination dataset to create for the subscriber. - * @type string $name - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * BigQuery destination dataset to create for the subscriber. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DestinationDataset destination_dataset = 3; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDataset|null - */ - public function getDestinationDataset() - { - return $this->readOneof(3); - } - - public function hasDestinationDataset() - { - return $this->hasOneof(3); - } - - /** - * BigQuery destination dataset to create for the subscriber. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DestinationDataset destination_dataset = 3; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDataset $var - * @return $this - */ - public function setDestinationDataset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\DestinationDataset::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * @return string - */ - public function getDestination() - { - return $this->whichOneof("destination"); - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingResponse.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingResponse.php deleted file mode 100644 index c758a899481a..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/SubscribeListingResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.SubscribeListingResponse - */ -class SubscribeListingResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateDataExchangeRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateDataExchangeRequest.php deleted file mode 100644 index a39b0308867c..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateDataExchangeRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.UpdateDataExchangeRequest - */ -class UpdateDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange = null; - - /** - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange Required. The data exchange to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateDataExchangeRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $dataExchange, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDataExchange($dataExchange) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $data_exchange - * Required. The data exchange to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange|null - */ - public function getDataExchange() - { - return $this->data_exchange; - } - - public function hasDataExchange() - { - return isset($this->data_exchange); - } - - public function clearDataExchange() - { - unset($this->data_exchange); - } - - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange $var - * @return $this - */ - public function setDataExchange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange::class); - $this->data_exchange = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateListingRequest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateListingRequest.php deleted file mode 100644 index ff751eefdfe1..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/proto/src/Google/Cloud/BigQuery/AnalyticsHub/V1/UpdateListingRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.bigquery.analyticshub.v1.UpdateListingRequest - */ -class UpdateListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing = null; - - /** - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing Required. The listing to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\UpdateListingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setListing($listing) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * @type \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $listing - * Required. The listing to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Analyticshub\V1\Analyticshub::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing|null - */ - public function getListing() - { - return $this->listing; - } - - public function hasListing() - { - return isset($this->listing); - } - - public function clearListing() - { - unset($this->listing); - } - - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.analyticshub.v1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing $var - * @return $this - */ - public function setListing($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing::class); - $this->listing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php deleted file mode 100644 index be6d455c844d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_data_exchange.php +++ /dev/null @@ -1,91 +0,0 @@ -setDisplayName($dataExchangeDisplayName); - $request = (new CreateDataExchangeRequest()) - ->setParent($formattedParent) - ->setDataExchangeId($dataExchangeId) - ->setDataExchange($dataExchange); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->createDataExchange($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 = AnalyticsHubServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = '[DATA_EXCHANGE_ID]'; - $dataExchangeDisplayName = '[DISPLAY_NAME]'; - - create_data_exchange_sample($formattedParent, $dataExchangeId, $dataExchangeDisplayName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_CreateDataExchange_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_listing.php deleted file mode 100644 index 52594b2ff265..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/create_listing.php +++ /dev/null @@ -1,98 +0,0 @@ -setBigqueryDataset($listingBigqueryDataset) - ->setDisplayName($listingDisplayName); - $request = (new CreateListingRequest()) - ->setParent($formattedParent) - ->setListingId($listingId) - ->setListing($listing); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->createListing($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - $listingId = '[LISTING_ID]'; - $listingDisplayName = '[DISPLAY_NAME]'; - - create_listing_sample($formattedParent, $listingId, $listingDisplayName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_CreateListing_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php deleted file mode 100644 index 5b9c9b4b3b46..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_data_exchange.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $analyticsHubServiceClient->deleteDataExchange($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - delete_data_exchange_sample($formattedName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_DeleteDataExchange_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_listing.php deleted file mode 100644 index cc52559e7c05..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/delete_listing.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $analyticsHubServiceClient->deleteListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - delete_listing_sample($formattedName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_DeleteListing_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php deleted file mode 100644 index dc75a21f8f54..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_data_exchange.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->getDataExchange($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - get_data_exchange_sample($formattedName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_GetDataExchange_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php deleted file mode 100644 index 5316416ffc49..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_iam_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1_generated_AnalyticsHubService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_listing.php deleted file mode 100644 index 67f2f77def0d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/get_listing.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->getListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - get_listing_sample($formattedName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_GetListing_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php deleted file mode 100644 index 656ed6c72959..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_data_exchanges.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listDataExchanges($request); - - /** @var DataExchange $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 = AnalyticsHubServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_data_exchanges_sample($formattedParent); -} -// [END analyticshub_v1_generated_AnalyticsHubService_ListDataExchanges_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_listings.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_listings.php deleted file mode 100644 index c9703d121238..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_listings.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listListings($request); - - /** @var Listing $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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - list_listings_sample($formattedParent); -} -// [END analyticshub_v1_generated_AnalyticsHubService_ListListings_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php deleted file mode 100644 index 3ef4b508434c..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/list_org_data_exchanges.php +++ /dev/null @@ -1,77 +0,0 @@ -setOrganization($organization); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listOrgDataExchanges($request); - - /** @var DataExchange $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 -{ - $organization = '[ORGANIZATION]'; - - list_org_data_exchanges_sample($organization); -} -// [END analyticshub_v1_generated_AnalyticsHubService_ListOrgDataExchanges_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php deleted file mode 100644 index 412a15bb6416..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1_generated_AnalyticsHubService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php deleted file mode 100644 index e5f4a3823d3d..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/subscribe_listing.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var SubscribeListingResponse $response */ - $response = $analyticsHubServiceClient->subscribeListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - subscribe_listing_sample($formattedName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_SubscribeListing_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php deleted file mode 100644 index 89c55f4c5e23..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,78 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1_generated_AnalyticsHubService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php deleted file mode 100644 index abac3b719234..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_data_exchange.php +++ /dev/null @@ -1,79 +0,0 @@ -setDisplayName($dataExchangeDisplayName); - $request = (new UpdateDataExchangeRequest()) - ->setUpdateMask($updateMask) - ->setDataExchange($dataExchange); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->updateDataExchange($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 -{ - $dataExchangeDisplayName = '[DISPLAY_NAME]'; - - update_data_exchange_sample($dataExchangeDisplayName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_UpdateDataExchange_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_listing.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_listing.php deleted file mode 100644 index 5752f2c98290..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/samples/V1/AnalyticsHubServiceClient/update_listing.php +++ /dev/null @@ -1,82 +0,0 @@ -setBigqueryDataset($listingBigqueryDataset) - ->setDisplayName($listingDisplayName); - $request = (new UpdateListingRequest()) - ->setUpdateMask($updateMask) - ->setListing($listing); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->updateListing($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 -{ - $listingDisplayName = '[DISPLAY_NAME]'; - - update_listing_sample($listingDisplayName); -} -// [END analyticshub_v1_generated_AnalyticsHubService_UpdateListing_sync] diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/AnalyticsHubServiceClient.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/AnalyticsHubServiceClient.php deleted file mode 100644 index dafddc678edb..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/AnalyticsHubServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $dataExchangeId = 'data_exchange_id'; - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * 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. - */ -class AnalyticsHubServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.bigquery.analyticshub.v1.AnalyticsHubService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'analyticshub.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/bigquery', - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $dataExchangeNameTemplate; - - private static $datasetNameTemplate; - - private static $listingNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/analytics_hub_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/analytics_hub_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/analytics_hub_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/analytics_hub_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getDataExchangeNameTemplate() - { - if (self::$dataExchangeNameTemplate == null) { - self::$dataExchangeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataExchanges/{data_exchange}'); - } - - return self::$dataExchangeNameTemplate; - } - - private static function getDatasetNameTemplate() - { - if (self::$datasetNameTemplate == null) { - self::$datasetNameTemplate = new PathTemplate('projects/{project}/datasets/{dataset}'); - } - - return self::$datasetNameTemplate; - } - - private static function getListingNameTemplate() - { - if (self::$listingNameTemplate == null) { - self::$listingNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}'); - } - - return self::$listingNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'dataExchange' => self::getDataExchangeNameTemplate(), - 'dataset' => self::getDatasetNameTemplate(), - 'listing' => self::getListingNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * data_exchange resource. - * - * @param string $project - * @param string $location - * @param string $dataExchange - * - * @return string The formatted data_exchange resource. - */ - public static function dataExchangeName($project, $location, $dataExchange) - { - return self::getDataExchangeNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_exchange' => $dataExchange, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dataset - * resource. - * - * @param string $project - * @param string $dataset - * - * @return string The formatted dataset resource. - */ - public static function datasetName($project, $dataset) - { - return self::getDatasetNameTemplate()->render([ - 'project' => $project, - 'dataset' => $dataset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a listing - * resource. - * - * @param string $project - * @param string $location - * @param string $dataExchange - * @param string $listing - * - * @return string The formatted listing resource. - */ - public static function listingName($project, $location, $dataExchange, $listing) - { - return self::getListingNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_exchange' => $dataExchange, - 'listing' => $listing, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - dataExchange: projects/{project}/locations/{location}/dataExchanges/{data_exchange} - * - dataset: projects/{project}/datasets/{dataset} - * - listing: projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticshub.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a new data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $dataExchangeId = 'data_exchange_id'; - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * @param string $dataExchangeId Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @param DataExchange $dataExchange Required. The data exchange to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange - * - * @throws ApiException if the remote call fails - */ - public function createDataExchange($parent, $dataExchangeId, $dataExchange, array $optionalArgs = []) - { - $request = new CreateDataExchangeRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDataExchangeId($dataExchangeId); - $request->setDataExchange($dataExchange); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $listingId = 'listing_id'; - * $listing = new Listing(); - * $response = $analyticsHubServiceClient->createListing($formattedParent, $listingId, $listing); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param string $listingId Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @param Listing $listing Required. The listing to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing - * - * @throws ApiException if the remote call fails - */ - public function createListing($parent, $listingId, $listing, array $optionalArgs = []) - { - $request = new CreateListingRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setListingId($listingId); - $request->setListing($listing); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateListing', Listing::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes an existing data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $analyticsHubServiceClient->deleteDataExchange($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteDataExchange($name, array $optionalArgs = []) - { - $request = new DeleteDataExchangeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteDataExchange', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $analyticsHubServiceClient->deleteListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteListing($name, array $optionalArgs = []) - { - $request = new DeleteListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteListing', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of a data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $response = $analyticsHubServiceClient->getDataExchange($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange - * - * @throws ApiException if the remote call fails - */ - public function getDataExchange($name, array $optionalArgs = []) - { - $request = new GetDataExchangeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the IAM policy. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $response = $analyticsHubServiceClient->getIamPolicy($resource); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of a listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $response = $analyticsHubServiceClient->getListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing - * - * @throws ApiException if the remote call fails - */ - public function getListing($name, array $optionalArgs = []) - { - $request = new GetListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetListing', Listing::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists all data exchanges in a given project and location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listDataExchanges($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listDataExchanges($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listDataExchanges($parent, array $optionalArgs = []) - { - $request = new ListDataExchangesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDataExchanges', $optionalArgs, ListDataExchangesResponse::class, $request); - } - - /** - * Lists all listings in a given project and location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listListings($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listListings($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listListings($parent, array $optionalArgs = []) - { - $request = new ListListingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListListings', $optionalArgs, ListListingsResponse::class, $request); - } - - /** - * Lists all data exchanges from projects in a given organization and - * location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $organization = 'organization'; - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listOrgDataExchanges($organization); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listOrgDataExchanges($organization); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $organization Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listOrgDataExchanges($organization, array $optionalArgs = []) - { - $request = new ListOrgDataExchangesRequest(); - $requestParamHeaders = []; - $request->setOrganization($organization); - $requestParamHeaders['organization'] = $organization; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListOrgDataExchanges', $optionalArgs, ListOrgDataExchangesResponse::class, $request); - } - - /** - * Sets the IAM policy. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $analyticsHubServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Subscribes to a listing. - * - * Currently, with Analytics Hub, you can create listings that - * reference only BigQuery datasets. - * Upon subscription to a listing for a BigQuery dataset, Analytics Hub - * creates a linked dataset in the subscriber's project. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $response = $analyticsHubServiceClient->subscribeListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type DestinationDataset $destinationDataset - * BigQuery destination dataset to create for the subscriber. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingResponse - * - * @throws ApiException if the remote call fails - */ - public function subscribeListing($name, array $optionalArgs = []) - { - $request = new SubscribeListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['destinationDataset'])) { - $request->setDestinationDataset($optionalArgs['destinationDataset']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SubscribeListing', SubscribeListingResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the permissions that a caller has. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $analyticsHubServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an existing data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->updateDataExchange($updateMask, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * @param DataExchange $dataExchange Required. The data exchange to update. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange - * - * @throws ApiException if the remote call fails - */ - public function updateDataExchange($updateMask, $dataExchange, array $optionalArgs = []) - { - $request = new UpdateDataExchangeRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setDataExchange($dataExchange); - $requestParamHeaders['data_exchange.name'] = $dataExchange->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an existing listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $listing = new Listing(); - * $response = $analyticsHubServiceClient->updateListing($updateMask, $listing); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * @param Listing $listing Required. The listing to update. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\AnalyticsHub\V1\Listing - * - * @throws ApiException if the remote call fails - */ - public function updateListing($updateMask, $listing, array $optionalArgs = []) - { - $request = new UpdateListingRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setListing($listing); - $requestParamHeaders['listing.name'] = $listing->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateListing', Listing::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/gapic_metadata.json deleted file mode 100644 index b8fd033b4997..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.bigquery.analyticshub.v1", - "libraryPackage": "Google\\Cloud\\BigQuery\\AnalyticsHub\\V1", - "services": { - "AnalyticsHubService": { - "clients": { - "grpc": { - "libraryClient": "AnalyticsHubServiceGapicClient", - "rpcs": { - "CreateDataExchange": { - "methods": [ - "createDataExchange" - ] - }, - "CreateListing": { - "methods": [ - "createListing" - ] - }, - "DeleteDataExchange": { - "methods": [ - "deleteDataExchange" - ] - }, - "DeleteListing": { - "methods": [ - "deleteListing" - ] - }, - "GetDataExchange": { - "methods": [ - "getDataExchange" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "GetListing": { - "methods": [ - "getListing" - ] - }, - "ListDataExchanges": { - "methods": [ - "listDataExchanges" - ] - }, - "ListListings": { - "methods": [ - "listListings" - ] - }, - "ListOrgDataExchanges": { - "methods": [ - "listOrgDataExchanges" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "SubscribeListing": { - "methods": [ - "subscribeListing" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - }, - "UpdateDataExchange": { - "methods": [ - "updateDataExchange" - ] - }, - "UpdateListing": { - "methods": [ - "updateListing" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_client_config.json b/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_client_config.json deleted file mode 100644 index 382274bcf0ec..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_client_config.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "interfaces": { - "google.cloud.bigquery.analyticshub.v1.AnalyticsHubService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "DEADLINE_EXCEEDED", - "UNAVAILABLE" - ] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDataExchanges": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListListings": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListOrgDataExchanges": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SubscribeListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_descriptor_config.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_descriptor_config.php deleted file mode 100644 index 98a467f77d95..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_descriptor_config.php +++ /dev/null @@ -1,220 +0,0 @@ - [ - 'google.cloud.bigquery.analyticshub.v1.AnalyticsHubService' => [ - 'CreateDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'GetListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListDataExchanges' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataExchanges', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListDataExchangesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListListings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListings', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListListingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListOrgDataExchanges' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataExchanges', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\ListOrgDataExchangesResponse', - 'headerParams' => [ - [ - 'keyName' => 'organization', - 'fieldAccessors' => [ - 'getOrganization', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'SubscribeListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\SubscribeListingResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'data_exchange.name', - 'fieldAccessors' => [ - 'getDataExchange', - 'getName', - ], - ], - ], - ], - 'UpdateListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\AnalyticsHub\V1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'listing.name', - 'fieldAccessors' => [ - 'getListing', - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'dataExchange' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}', - 'dataset' => 'projects/{project}/datasets/{dataset}', - 'listing' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_rest_client_config.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_rest_client_config.php deleted file mode 100644 index e3175b88147a..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/src/V1/resources/analytics_hub_service_rest_client_config.php +++ /dev/null @@ -1,216 +0,0 @@ - [ - 'google.cloud.bigquery.analyticshub.v1.AnalyticsHubService' => [ - 'CreateDataExchange' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dataExchanges', - 'body' => 'data_exchange', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'data_exchange_id', - ], - ], - 'CreateListing' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/dataExchanges/*}/listings', - 'body' => 'listing', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'listing_id', - ], - ], - 'DeleteDataExchange' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataExchanges/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteListing' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDataExchange' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataExchanges/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*}:getIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:getIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'GetListing' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListDataExchanges' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dataExchanges', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListListings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/dataExchanges/*}/listings', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListOrgDataExchanges' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{organization=organizations/*/locations/*}/dataExchanges', - 'placeholders' => [ - 'organization' => [ - 'getters' => [ - 'getOrganization', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SubscribeListing' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataExchanges/*/listings/*}:subscribe', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataExchange' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{data_exchange.name=projects/*/locations/*/dataExchanges/*}', - 'body' => 'data_exchange', - 'placeholders' => [ - 'data_exchange.name' => [ - 'getters' => [ - 'getDataExchange', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateListing' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{listing.name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'body' => 'listing', - 'placeholders' => [ - 'listing.name' => [ - 'getters' => [ - 'getListing', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/AnalyticsHubServiceClientTest.php b/owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/AnalyticsHubServiceClientTest.php deleted file mode 100644 index 7badb521464a..000000000000 --- a/owl-bot-staging/BigQueryAnalyticsHub/v1/tests/Unit/V1/AnalyticsHubServiceClientTest.php +++ /dev/null @@ -1,1117 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AnalyticsHubServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AnalyticsHubServiceClient($options); - } - - /** @test */ - public function createDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = 'dataExchangeId1402219426'; - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - $response = $gapicClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/CreateDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDataExchangeId(); - $this->assertProtobufEquals($dataExchangeId, $actualValue); - $actualValue = $actualRequestObject->getDataExchange(); - $this->assertProtobufEquals($dataExchange, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = 'dataExchangeId1402219426'; - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - try { - $gapicClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $listingId = 'listingId988969142'; - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - $response = $gapicClient->createListing($formattedParent, $listingId, $listing); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/CreateListing', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getListingId(); - $this->assertProtobufEquals($listingId, $actualValue); - $actualValue = $actualRequestObject->getListing(); - $this->assertProtobufEquals($listing, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $listingId = 'listingId988969142'; - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - try { - $gapicClient->createListing($formattedParent, $listingId, $listing); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $gapicClient->deleteDataExchange($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/DeleteDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->deleteDataExchange($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $gapicClient->deleteListing($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/DeleteListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->deleteListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $response = $gapicClient->getDataExchange($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->getDataExchange($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $response = $gapicClient->getListing($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/GetListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->getListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataExchangesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataExchangesElement = new DataExchange(); - $dataExchanges = [ - $dataExchangesElement, - ]; - $expectedResponse = new ListDataExchangesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataExchanges($dataExchanges); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDataExchanges($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataExchanges()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListDataExchanges', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataExchangesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDataExchanges($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listListingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $listingsElement = new Listing(); - $listings = [ - $listingsElement, - ]; - $expectedResponse = new ListListingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setListings($listings); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $response = $gapicClient->listListings($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListings()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListListings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listListingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->listListings($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOrgDataExchangesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataExchangesElement = new DataExchange(); - $dataExchanges = [ - $dataExchangesElement, - ]; - $expectedResponse = new ListOrgDataExchangesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataExchanges($dataExchanges); - $transport->addResponse($expectedResponse); - // Mock request - $organization = 'organization1178922291'; - $response = $gapicClient->listOrgDataExchanges($organization); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataExchanges()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/ListOrgDataExchanges', $actualFuncCall); - $actualValue = $actualRequestObject->getOrganization(); - $this->assertProtobufEquals($organization, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOrgDataExchangesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $organization = 'organization1178922291'; - try { - $gapicClient->listOrgDataExchanges($organization); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function subscribeListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new SubscribeListingResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $response = $gapicClient->subscribeListing($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/SubscribeListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function subscribeListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->subscribeListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $updateMask = new FieldMask(); - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - $response = $gapicClient->updateDataExchange($updateMask, $dataExchange); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/UpdateDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualRequestObject->getDataExchange(); - $this->assertProtobufEquals($dataExchange, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - try { - $gapicClient->updateDataExchange($updateMask, $dataExchange); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $updateMask = new FieldMask(); - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - $response = $gapicClient->updateListing($updateMask, $listing); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.analyticshub.v1.AnalyticsHubService/UpdateListing', $actualFuncCall); - $actualValue = $actualRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualRequestObject->getListing(); - $this->assertProtobufEquals($listing, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - try { - $gapicClient->updateListing($updateMask, $listing); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Dataexchange/V1Beta1/Dataexchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Dataexchange/V1Beta1/Dataexchange.php deleted file mode 100644 index ccdcb6ceb68678e4d252a84591f5a3ebc95f1f52..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 10020 zcmcgy&2JmW70*(ZY!79b8rcpl+x2>FH?r!GjnV`*V>ww-Yl@Bd5t4G8lmW3MN7BX= zx!GOXQCzh^3KZz2mjdlS&<~*KrH7(L+f$F}sVUHdPd&7Ux`$qiw1>W#omuX3Wrs_m zFSPZDPr--kxc6 zh?SD%^^#mH)nsiwU%LdNcCT->NJif2^>#WW-RkuE?R3-F`Jhj%{d8M*bn;0!*Wl^&C@L&r+rJHLkS2?o(R7`_dX!`Wiy5 zj&9qse-J%FGW;|9&5qHMZAW+D#}&hF7+u3L^p5cnAYPTX^^Q$IL3r+VzuR(*URS09 zrEZHXU6Wm%bnX?i2Oe6Lg_&jQG;mlw-*t%9)jRcdVz(^Abb3}9re-ob#PM8BpDbPD z%Tjg5w!Gxpn8}2UT$LTGPyDOPvPGP})qRcGO%)t?ztsOOv&zI6o1NsF`EVm0RUi1xY)9h(9dHV1PXMGbao+Etd zOMJ-C_n^_F;YY({nZU;vgX4j*b9~I?1)L@{pj=RNHgC|iY!AXVw6r(lA&-qauKX&7 zW@%f}cq7E~=m_n1NlBKLj;~GqRh`0T(QMnW&5pj`U_&u66vIgrZ}UC^g`1obBN9H3 zPMVgnr(64tRH*Jll5z_jFVo&{?~Wr~Lg%1= zgO8Zq6rfF<3W4pAz)palM~K=B&l*O15Xu-G;Hc?YYAe@yD-*Q*b1? z2Ab*UP13O;FQ=B`D_<8&jnF0z!IRo#%CxRy?YoAZM#n@p4bnTd_#%q?rs6o7x=;4q z7~vCW`T<4eMkW)xAt}F(qobQ{IpFtELUgYN4+|@f_)0#C@myUBNXuK43Gwu)GPcCR zvGH6up}+7xP(ag^au8PRb1OH;fmo#qD5NP0h_#MmUhBX$=t8utA-Px;Cy&EeeC0-z zm8kPX7jWag1#}Nq-RVI-+erk;HMeprib@fmtgD5mQvn@kWRW(EWSklLN))YLw{fjJ zhvqB-MA&v3daFfjJ2?wFS;vZKhcn{U}yIQ4|ujY%nhFV;26x7O_S`Ge6#HbnGylkmZ&?;FiF@>)n zdGL5MU!aCkQLT74Unvy}TCtWm0^8wfZ`Qh2DCH_@c_W{#CZ_QjguNjxTPl_c^!ZHi z`T7>j$(M?Wqu38ZD{7V8JBed~$#?QawV2JTn~CFr$vL$^ksxU33*L%3tyC?8YM33z zOX!L>u%W4&wT-M=ap7#{?`Vx`Hm?-{^(@9{&YM|)qm!CAffvyk?^$_kZ8M*3RJCla zR7uPQ?5JopHNTlS8F*MNmnyYtB7rZV3!WCf9`k2Kt7>W`yOEg3*U(jOO0A+oR)8#X z51YAJ%H^vy>O_n$qI3SKcePD6rB>Ri-$Y5e9BmLDkEpmMhi{@8Q-{6U;hXa{*aJUPFQZFh$FPS>X_Ipl z=wruCeTOt`I3coqVj3cd*dwQRpKubUd{;te4_V$e;e17K8O^cICkTxVcF;{Qa_bYw zAQ4Y?$%jtEX9%MgN&}svc9g80Lp=fHvS;n+UE?E{2ztCTHY(EZN$C9HD}3=_@1Zj} z5(v47`0W6%{wj<2^60!(`6I+LYZ2HI{B9K5C&;G@C=p17ATjjzNRcUw<4=$%j9(}} z12kJEta~V$uc3IK4L0aWhV#uuvDtZ4&^w|soncF9{!MJ@H_+L2(jkW%I%!b9g%)V$ z(*HneZ4u2khPp%KY#Ft59-vdf^?Ai;KwY^_yfM5iygv#%=6Igo6N+da%7jl7sBZ=; z73k?aAM-F7%GfBI?4xlNsQwnw;Fx~=DXD}Wd3-C;Iqsv zf$=SS3!QSaf5@;2V)X|JJzwoN>C49^8B+TmT7cIH;#ljQap-G>_{!}lDHuL*!kK1# ztJhAjQ>L&?SwzV&2Df-tetH2dsN!|RM!#7l)&m0$<^Pb-JjLtp-!@*4f+{4=YiCiL zP>XB2lKc42fBQk~27c9hAO6UtDXSh|TK2sySsr>z@>u1p27f2!c9!8?A4hs?K;aH+ z5QsOTA`UC!pzkrzS*#8~`x(iq{|`I;Z2SQ(ga0C-lS6a>uSKzYNLXMWo24mQIKcFk z-c!Om^bTzK;IYbH4&whvaL@^n5gaKC!}62EYcqH`Wz77|xUT~Q)p@L*afFR-T z#}E#amuTq2@{^-~$k1=CtPc`7V0bD@s6)Ou8_;##N6_$ZAsxabDVjsV^1>l!M8$Z- zkA2e+xxDNPb`*djm;WxIS=wmme@epe>tel8sg95o2EQ@B0^X7;;gjzlJf(i6G3Y+Xq$>}6B#pN z89^%_t8={lbllX${|2-Ho)`^nKy)IsCPQ0W$qzaWw=qhO@dwn0dV#A7w3y!k^Z*l$ z20b7upg*m#@HAca#d5+l{jY=)!+a5Eqg3Fqw7?LFK8BU>e)ArSXIXi35YI6YXKX?3 zGt#nXv5>d3&_cWq;8+pR;ZrDldQJHU1+vpabKH;M$}c2l>rW&lH!xOwZylA#(8~^< zHDKtwZ!49twFT06NHHzh*{W}`5On|G7XlsL$Nztz4=Kh!2AWiZ(;QumSbK(T)4Lsb zX(+DYDZ&lcMwrPH_&07={8Ca1W5@9z{3fYAQ{ Dv6M-q diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/AnalyticsHubServiceGrpcClient.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/AnalyticsHubServiceGrpcClient.php deleted file mode 100644 index 1c5e8b4b0557..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/AnalyticsHubServiceGrpcClient.php +++ /dev/null @@ -1,271 +0,0 @@ -_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListDataExchanges', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesResponse', 'decode'], - $metadata, $options); - } - - /** - * Lists all data exchanges from projects in a given organization and - * location. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListOrgDataExchanges(\Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListOrgDataExchanges', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of a data exchange. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\GetDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetDataExchange(\Google\Cloud\BigQuery\DataExchange\V1beta1\GetDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetDataExchange', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Creates a new data exchange. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateDataExchange(\Google\Cloud\BigQuery\DataExchange\V1beta1\CreateDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/CreateDataExchange', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Updates an existing data exchange. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateDataExchange(\Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/UpdateDataExchange', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', 'decode'], - $metadata, $options); - } - - /** - * Deletes an existing data exchange. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteDataExchangeRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteDataExchange(\Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteDataExchangeRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/DeleteDataExchange', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Lists all listings in a given project and location. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListListings(\Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListListings', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of a listing. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\GetListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetListing(\Google\Cloud\BigQuery\DataExchange\V1beta1\GetListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetListing', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Creates a new listing. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateListing(\Google\Cloud\BigQuery\DataExchange\V1beta1\CreateListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/CreateListing', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Updates an existing listing. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateListing(\Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/UpdateListing', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', 'decode'], - $metadata, $options); - } - - /** - * Deletes a listing. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteListing(\Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/DeleteListing', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Subscribes to a listing. - * - * Currently, with Analytics Hub, you can create listings that - * reference only BigQuery datasets. - * Upon subscription to a listing for a BigQuery dataset, Analytics Hub - * creates a linked dataset in the subscriber's project. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SubscribeListing(\Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/SubscribeListing', - $argument, - ['\Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the IAM policy. - * @param \Google\Cloud\Iam\V1\GetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetIamPolicy(\Google\Cloud\Iam\V1\GetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Sets the IAM policy. - * @param \Google\Cloud\Iam\V1\SetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SetIamPolicy(\Google\Cloud\Iam\V1\SetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/SetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Returns the permissions that a caller has. - * @param \Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TestIamPermissions(\Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/TestIamPermissions', - $argument, - ['\Google\Cloud\Iam\V1\TestIamPermissionsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateDataExchangeRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateDataExchangeRequest.php deleted file mode 100644 index 09056571a3e0..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateDataExchangeRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.CreateDataExchangeRequest - */ -class CreateDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange_id = ''; - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange = null; - - /** - * @param string $parent Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. Please see - * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange Required. The data exchange to create. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateDataExchangeRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange): self - { - return (new self()) - ->setParent($parent) - ->setDataExchange($dataExchange); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * @type string $data_exchange_id - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $data_exchange - * Required. The data exchange to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDataExchangeId() - { - return $this->data_exchange_id; - } - - /** - * Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string data_exchange_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDataExchangeId($var) - { - GPBUtil::checkString($var, True); - $this->data_exchange_id = $var; - - return $this; - } - - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange|null - */ - public function getDataExchange() - { - return $this->data_exchange; - } - - public function hasDataExchange() - { - return isset($this->data_exchange); - } - - public function clearDataExchange() - { - unset($this->data_exchange); - } - - /** - * Required. The data exchange to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $var - * @return $this - */ - public function setDataExchange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange::class); - $this->data_exchange = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateListingRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateListingRequest.php deleted file mode 100644 index 185295f4c739..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/CreateListingRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.CreateListingRequest - */ -class CreateListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing_id = ''; - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing = null; - - /** - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing Required. The listing to create. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\CreateListingRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing): self - { - return (new self()) - ->setParent($parent) - ->setListing($listing); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type string $listing_id - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing - * Required. The listing to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getListingId() - { - return $this->listing_id; - } - - /** - * Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * - * Generated from protobuf field string listing_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setListingId($var) - { - GPBUtil::checkString($var, True); - $this->listing_id = $var; - - return $this; - } - - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing|null - */ - public function getListing() - { - return $this->listing; - } - - public function hasListing() - { - return isset($this->listing); - } - - public function clearListing() - { - unset($this->listing); - } - - /** - * Required. The listing to create. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $var - * @return $this - */ - public function setListing($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing::class); - $this->listing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataExchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataExchange.php deleted file mode 100644 index 6e9c67d93f21..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataExchange.php +++ /dev/null @@ -1,329 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DataExchange - */ -class DataExchange extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $display_name = ''; - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $documentation = ''; - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $listing_count = 0; - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $icon = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type string $display_name - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * @type string $description - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * @type string $primary_contact - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * @type string $documentation - * Optional. Documentation describing the data exchange. - * @type int $listing_count - * Output only. Number of listings contained in the data exchange. - * @type string $icon - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Required. Human-readable display name of the data exchange. The display name must - * contain only Unicode letters, numbers (0-9), underscores (_), dashes (-), - * spaces ( ), ampersands (&) and must not start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. Description of the data exchange. The description must not contain Unicode - * non-characters as well as C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the primary point of contact of the data exchange. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDocumentation() - { - return $this->documentation; - } - - /** - * Optional. Documentation describing the data exchange. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDocumentation($var) - { - GPBUtil::checkString($var, True); - $this->documentation = $var; - - return $this; - } - - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getListingCount() - { - return $this->listing_count; - } - - /** - * Output only. Number of listings contained in the data exchange. - * - * Generated from protobuf field int32 listing_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setListingCount($var) - { - GPBUtil::checkInt32($var); - $this->listing_count = $var; - - return $this; - } - - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getIcon() - { - return $this->icon; - } - - /** - * Optional. Base64 encoded image representing the data exchange. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the content of the fields are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setIcon($var) - { - GPBUtil::checkString($var, False); - $this->icon = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataProvider.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataProvider.php deleted file mode 100644 index a84fe678974c..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DataProvider.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DataProvider - */ -class DataProvider extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name = ''; - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Optional. Name of the data provider. - * @type string $primary_contact - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Optional. Name of the data provider. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the data provider. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteDataExchangeRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteDataExchangeRequest.php deleted file mode 100644 index a51e62da4faf..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteDataExchangeRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DeleteDataExchangeRequest - */ -class DeleteDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteDataExchangeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteListingRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteListingRequest.php deleted file mode 100644 index 3a38544c15a9..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DeleteListingRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DeleteListingRequest - */ -class DeleteListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DeleteListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDataset.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDataset.php deleted file mode 100644 index 5cdedbec98c6..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDataset.php +++ /dev/null @@ -1,311 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DestinationDataset - */ -class DestinationDataset extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dataset_reference = null; - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $friendly_name = null; - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = null; - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $location = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDatasetReference $dataset_reference - * Required. A reference that identifies the destination dataset. - * @type \Google\Protobuf\StringValue $friendly_name - * Optional. A descriptive name for the dataset. - * @type \Google\Protobuf\StringValue $description - * Optional. A user-friendly description of the dataset. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * @type string $location - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDatasetReference|null - */ - public function getDatasetReference() - { - return $this->dataset_reference; - } - - public function hasDatasetReference() - { - return isset($this->dataset_reference); - } - - public function clearDatasetReference() - { - unset($this->dataset_reference); - } - - /** - * Required. A reference that identifies the destination dataset. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DestinationDatasetReference dataset_reference = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDatasetReference $var - * @return $this - */ - public function setDatasetReference($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDatasetReference::class); - $this->dataset_reference = $var; - - return $this; - } - - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\StringValue|null - */ - public function getFriendlyName() - { - return $this->friendly_name; - } - - public function hasFriendlyName() - { - return isset($this->friendly_name); - } - - public function clearFriendlyName() - { - unset($this->friendly_name); - } - - /** - * Returns the unboxed value from getFriendlyName() - - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string|null - */ - public function getFriendlyNameUnwrapped() - { - return $this->readWrapperValue("friendly_name"); - } - - /** - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\StringValue $var - * @return $this - */ - public function setFriendlyName($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class); - $this->friendly_name = $var; - - return $this; - } - - /** - * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object. - - * Optional. A descriptive name for the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue friendly_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string|null $var - * @return $this - */ - public function setFriendlyNameUnwrapped($var) - { - $this->writeWrapperValue("friendly_name", $var); - return $this;} - - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\StringValue|null - */ - public function getDescription() - { - return $this->description; - } - - public function hasDescription() - { - return isset($this->description); - } - - public function clearDescription() - { - unset($this->description); - } - - /** - * Returns the unboxed value from getDescription() - - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string|null - */ - public function getDescriptionUnwrapped() - { - return $this->readWrapperValue("description"); - } - - /** - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\StringValue $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class); - $this->description = $var; - - return $this; - } - - /** - * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object. - - * Optional. A user-friendly description of the dataset. - * - * Generated from protobuf field .google.protobuf.StringValue description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string|null $var - * @return $this - */ - public function setDescriptionUnwrapped($var) - { - $this->writeWrapperValue("description", $var); - return $this;} - - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. The labels associated with this dataset. You can use these - * to organize and group your datasets. - * You can set this property when inserting or updating a dataset. - * See https://cloud.google.com/resource-manager/docs/creating-managing-labels - * for more information. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * Required. The geographic location where the dataset should reside. See - * https://cloud.google.com/bigquery/docs/locations for supported - * locations. - * - * Generated from protobuf field string location = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDatasetReference.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDatasetReference.php deleted file mode 100644 index cdfc01fa84a4..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/DestinationDatasetReference.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.DestinationDatasetReference - */ -class DestinationDatasetReference extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dataset_id = ''; - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dataset_id - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * @type string $project_id - * Required. The ID of the project containing this dataset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDatasetId() - { - return $this->dataset_id; - } - - /** - * Required. A unique ID for this dataset, without the project name. The ID - * must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). - * The maximum length is 1,024 characters. - * - * Generated from protobuf field string dataset_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDatasetId($var) - { - GPBUtil::checkString($var, True); - $this->dataset_id = $var; - - return $this; - } - - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. The ID of the project containing this dataset. - * - * Generated from protobuf field string project_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetDataExchangeRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetDataExchangeRequest.php deleted file mode 100644 index 1589433adf0e..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetDataExchangeRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.GetDataExchangeRequest - */ -class GetDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\GetDataExchangeRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetListingRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetListingRequest.php deleted file mode 100644 index 4833f1fea1f0..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/GetListingRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.GetListingRequest - */ -class GetListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\GetListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesRequest.php deleted file mode 100644 index 0d3c1e996b60..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListDataExchangesRequest - */ -class ListDataExchangesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. Please see - * {@see AnalyticsHubServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesResponse.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesResponse.php deleted file mode 100644 index e4bc976a6fda..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListDataExchangesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListDataExchangesResponse - */ -class ListDataExchangesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - */ - private $data_exchanges; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $data_exchanges - * The list of data exchanges. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataExchanges() - { - return $this->data_exchanges; - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - * @param array<\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataExchanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange::class); - $this->data_exchanges = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsRequest.php deleted file mode 100644 index 453823573a96..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListListingsRequest - */ -class ListListingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. Please see - * {@see AnalyticsHubServiceClient::dataExchangeName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsResponse.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsResponse.php deleted file mode 100644 index 52139dd5acde..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListListingsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListListingsResponse - */ -class ListListingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing listings = 1; - */ - private $listings; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing>|\Google\Protobuf\Internal\RepeatedField $listings - * The list of Listing. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing listings = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListings() - { - return $this->listings; - } - - /** - * The list of Listing. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing listings = 1; - * @param array<\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing::class); - $this->listings = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesRequest.php deleted file mode 100644 index f6b4ab045d71..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListOrgDataExchangesRequest - */ -class ListOrgDataExchangesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $organization = ''; - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $organization Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesRequest - * - * @experimental - */ - public static function build(string $organization): self - { - return (new self()) - ->setOrganization($organization); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $organization - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * @type int $page_size - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * @type string $page_token - * Page token, returned by a previous call, to request the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getOrganization() - { - return $this->organization; - } - - /** - * Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * - * Generated from protobuf field string organization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setOrganization($var) - { - GPBUtil::checkString($var, True); - $this->organization = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response page. Leverage - * the page tokens to iterate through the entire collection. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page token, returned by a previous call, to request the next page of - * results. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesResponse.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesResponse.php deleted file mode 100644 index 10b57cdff8e8..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/ListOrgDataExchangesResponse.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.ListOrgDataExchangesResponse - */ -class ListOrgDataExchangesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - */ - private $data_exchanges; - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $data_exchanges - * The list of data exchanges. - * @type string $next_page_token - * A token to request the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataExchanges() - { - return $this->data_exchanges; - } - - /** - * The list of data exchanges. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchanges = 1; - * @param array<\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataExchanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange::class); - $this->data_exchanges = $arr; - - return $this; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token to request the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing.php deleted file mode 100644 index 97a1b7104982..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing.php +++ /dev/null @@ -1,540 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.Listing - */ -class Listing extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $display_name = ''; - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $documentation = ''; - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $icon = ''; - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $data_provider = null; - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $categories; - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $publisher = null; - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_access = ''; - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource $bigquery_dataset - * Required. Shared dataset i.e. BigQuery dataset source. - * @type string $name - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * @type string $display_name - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * @type string $description - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * @type string $primary_contact - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * @type string $documentation - * Optional. Documentation describing the listing. - * @type int $state - * Output only. Current state of the listing. - * @type string $icon - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\DataProvider $data_provider - * Optional. Details of the data provider who owns the source data. - * @type array|\Google\Protobuf\Internal\RepeatedField $categories - * Optional. Categories of the listing. Up to two categories are allowed. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\Publisher $publisher - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * @type string $request_access - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. Shared dataset i.e. BigQuery dataset source. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing.BigQueryDatasetSource bigquery_dataset = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource|null - */ - public function getBigqueryDataset() - { - return $this->readOneof(6); - } - - public function hasBigqueryDataset() - { - return $this->hasOneof(6); - } - - /** - * Required. Shared dataset i.e. BigQuery dataset source. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing.BigQueryDatasetSource bigquery_dataset = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource $var - * @return $this - */ - public function setBigqueryDataset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\BigQueryDatasetSource::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Required. Human-readable display name of the listing. The display name must contain - * only Unicode letters, numbers (0-9), underscores (_), dashes (-), spaces - * ( ), ampersands (&) and can't start or end with spaces. - * Default value is an empty string. - * Max length: 63 bytes. - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. Short description of the listing. The description must not contain - * Unicode non-characters and C0 and C1 control codes except tabs (HT), - * new lines (LF), carriage returns (CR), and page breaks (FF). - * Default value is an empty string. - * Max length: 2000 bytes. - * - * Generated from protobuf field string description = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the primary point of contact of the listing. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDocumentation() - { - return $this->documentation; - } - - /** - * Optional. Documentation describing the listing. - * - * Generated from protobuf field string documentation = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDocumentation($var) - { - GPBUtil::checkString($var, True); - $this->documentation = $var; - - return $this; - } - - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. Current state of the listing. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\State::class); - $this->state = $var; - - return $this; - } - - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getIcon() - { - return $this->icon; - } - - /** - * Optional. Base64 encoded image representing the listing. Max Size: 3.0MiB - * Expected image dimensions are 512x512 pixels, however the API only - * performs validation on size of the encoded data. - * Note: For byte fields, the contents of the field are base64-encoded (which - * increases the size of the data by 33-36%) when using JSON on the wire. - * - * Generated from protobuf field bytes icon = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setIcon($var) - { - GPBUtil::checkString($var, False); - $this->icon = $var; - - return $this; - } - - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataProvider|null - */ - public function getDataProvider() - { - return $this->data_provider; - } - - public function hasDataProvider() - { - return isset($this->data_provider); - } - - public function clearDataProvider() - { - unset($this->data_provider); - } - - /** - * Optional. Details of the data provider who owns the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataProvider data_provider = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataProvider $var - * @return $this - */ - public function setDataProvider($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataProvider::class); - $this->data_provider = $var; - - return $this; - } - - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCategories() - { - return $this->categories; - } - - /** - * Optional. Categories of the listing. Up to two categories are allowed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.dataexchange.v1beta1.Listing.Category categories = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCategories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing\Category::class); - $this->categories = $arr; - - return $this; - } - - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Publisher|null - */ - public function getPublisher() - { - return $this->publisher; - } - - public function hasPublisher() - { - return isset($this->publisher); - } - - public function clearPublisher() - { - unset($this->publisher); - } - - /** - * Optional. Details of the publisher who owns the listing and who can share - * the source data. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Publisher publisher = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Publisher $var - * @return $this - */ - public function setPublisher($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\Publisher::class); - $this->publisher = $var; - - return $this; - } - - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestAccess() - { - return $this->request_access; - } - - /** - * Optional. Email or URL of the request access of the listing. - * Subscribers can use this reference to request access. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string request_access = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRequestAccess($var) - { - GPBUtil::checkString($var, True); - $this->request_access = $var; - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/BigQueryDatasetSource.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/BigQueryDatasetSource.php deleted file mode 100644 index 46799e57be56..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/BigQueryDatasetSource.php +++ /dev/null @@ -1,80 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.Listing.BigQueryDatasetSource - */ -class BigQueryDatasetSource extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - */ - protected $dataset = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dataset - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getDataset() - { - return $this->dataset; - } - - /** - * Resource name of the dataset source for this listing. - * e.g. `projects/myproject/datasets/123` - * - * Generated from protobuf field string dataset = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setDataset($var) - { - GPBUtil::checkString($var, True); - $this->dataset = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(BigQueryDatasetSource::class, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing_BigQueryDatasetSource::class); - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/Category.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/Category.php deleted file mode 100644 index 49feae1ddd69..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/Category.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.Listing.Category - */ -class Category -{ - /** - * Generated from protobuf enum CATEGORY_UNSPECIFIED = 0; - */ - const CATEGORY_UNSPECIFIED = 0; - /** - * Generated from protobuf enum CATEGORY_OTHERS = 1; - */ - const CATEGORY_OTHERS = 1; - /** - * Generated from protobuf enum CATEGORY_ADVERTISING_AND_MARKETING = 2; - */ - const CATEGORY_ADVERTISING_AND_MARKETING = 2; - /** - * Generated from protobuf enum CATEGORY_COMMERCE = 3; - */ - const CATEGORY_COMMERCE = 3; - /** - * Generated from protobuf enum CATEGORY_CLIMATE_AND_ENVIRONMENT = 4; - */ - const CATEGORY_CLIMATE_AND_ENVIRONMENT = 4; - /** - * Generated from protobuf enum CATEGORY_DEMOGRAPHICS = 5; - */ - const CATEGORY_DEMOGRAPHICS = 5; - /** - * Generated from protobuf enum CATEGORY_ECONOMICS = 6; - */ - const CATEGORY_ECONOMICS = 6; - /** - * Generated from protobuf enum CATEGORY_EDUCATION = 7; - */ - const CATEGORY_EDUCATION = 7; - /** - * Generated from protobuf enum CATEGORY_ENERGY = 8; - */ - const CATEGORY_ENERGY = 8; - /** - * Generated from protobuf enum CATEGORY_FINANCIAL = 9; - */ - const CATEGORY_FINANCIAL = 9; - /** - * Generated from protobuf enum CATEGORY_GAMING = 10; - */ - const CATEGORY_GAMING = 10; - /** - * Generated from protobuf enum CATEGORY_GEOSPATIAL = 11; - */ - const CATEGORY_GEOSPATIAL = 11; - /** - * Generated from protobuf enum CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE = 12; - */ - const CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE = 12; - /** - * Generated from protobuf enum CATEGORY_MEDIA = 13; - */ - const CATEGORY_MEDIA = 13; - /** - * Generated from protobuf enum CATEGORY_PUBLIC_SECTOR = 14; - */ - const CATEGORY_PUBLIC_SECTOR = 14; - /** - * Generated from protobuf enum CATEGORY_RETAIL = 15; - */ - const CATEGORY_RETAIL = 15; - /** - * Generated from protobuf enum CATEGORY_SPORTS = 16; - */ - const CATEGORY_SPORTS = 16; - /** - * Generated from protobuf enum CATEGORY_SCIENCE_AND_RESEARCH = 17; - */ - const CATEGORY_SCIENCE_AND_RESEARCH = 17; - /** - * Generated from protobuf enum CATEGORY_TRANSPORTATION_AND_LOGISTICS = 18; - */ - const CATEGORY_TRANSPORTATION_AND_LOGISTICS = 18; - /** - * Generated from protobuf enum CATEGORY_TRAVEL_AND_TOURISM = 19; - */ - const CATEGORY_TRAVEL_AND_TOURISM = 19; - - private static $valueToName = [ - self::CATEGORY_UNSPECIFIED => 'CATEGORY_UNSPECIFIED', - self::CATEGORY_OTHERS => 'CATEGORY_OTHERS', - self::CATEGORY_ADVERTISING_AND_MARKETING => 'CATEGORY_ADVERTISING_AND_MARKETING', - self::CATEGORY_COMMERCE => 'CATEGORY_COMMERCE', - self::CATEGORY_CLIMATE_AND_ENVIRONMENT => 'CATEGORY_CLIMATE_AND_ENVIRONMENT', - self::CATEGORY_DEMOGRAPHICS => 'CATEGORY_DEMOGRAPHICS', - self::CATEGORY_ECONOMICS => 'CATEGORY_ECONOMICS', - self::CATEGORY_EDUCATION => 'CATEGORY_EDUCATION', - self::CATEGORY_ENERGY => 'CATEGORY_ENERGY', - self::CATEGORY_FINANCIAL => 'CATEGORY_FINANCIAL', - self::CATEGORY_GAMING => 'CATEGORY_GAMING', - self::CATEGORY_GEOSPATIAL => 'CATEGORY_GEOSPATIAL', - self::CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE => 'CATEGORY_HEALTHCARE_AND_LIFE_SCIENCE', - self::CATEGORY_MEDIA => 'CATEGORY_MEDIA', - self::CATEGORY_PUBLIC_SECTOR => 'CATEGORY_PUBLIC_SECTOR', - self::CATEGORY_RETAIL => 'CATEGORY_RETAIL', - self::CATEGORY_SPORTS => 'CATEGORY_SPORTS', - self::CATEGORY_SCIENCE_AND_RESEARCH => 'CATEGORY_SCIENCE_AND_RESEARCH', - self::CATEGORY_TRANSPORTATION_AND_LOGISTICS => 'CATEGORY_TRANSPORTATION_AND_LOGISTICS', - self::CATEGORY_TRAVEL_AND_TOURISM => 'CATEGORY_TRAVEL_AND_TOURISM', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Category::class, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing_Category::class); - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/State.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/State.php deleted file mode 100644 index b32889752911..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing/State.php +++ /dev/null @@ -1,58 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.Listing.State - */ -class State -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Subscribable state. Users with dataexchange.listings.subscribe permission - * can subscribe to this listing. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing_State::class); - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_BigQueryDatasetSource.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_BigQueryDatasetSource.php deleted file mode 100644 index abdbde3725fa..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/Listing_BigQueryDatasetSource.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.Publisher - */ -class Publisher extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name = ''; - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $primary_contact = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Optional. Name of the listing publisher. - * @type string $primary_contact - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Optional. Name of the listing publisher. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrimaryContact() - { - return $this->primary_contact; - } - - /** - * Optional. Email or URL of the listing publisher. - * Max Length: 1000 bytes. - * - * Generated from protobuf field string primary_contact = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrimaryContact($var) - { - GPBUtil::checkString($var, True); - $this->primary_contact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingRequest.php deleted file mode 100644 index 618a4dddf6d5..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingRequest.php +++ /dev/null @@ -1,128 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.SubscribeListingRequest - */ -class SubscribeListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - protected $destination; - - /** - * @param string $name Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. Please see - * {@see AnalyticsHubServiceClient::listingName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDataset $destination_dataset - * BigQuery destination dataset to create for the subscriber. - * @type string $name - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * BigQuery destination dataset to create for the subscriber. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DestinationDataset destination_dataset = 3; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDataset|null - */ - public function getDestinationDataset() - { - return $this->readOneof(3); - } - - public function hasDestinationDataset() - { - return $this->hasOneof(3); - } - - /** - * BigQuery destination dataset to create for the subscriber. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DestinationDataset destination_dataset = 3; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDataset $var - * @return $this - */ - public function setDestinationDataset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\DestinationDataset::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * @return string - */ - public function getDestination() - { - return $this->whichOneof("destination"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingResponse.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingResponse.php deleted file mode 100644 index d40416cb2840..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/SubscribeListingResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.SubscribeListingResponse - */ -class SubscribeListingResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateDataExchangeRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateDataExchangeRequest.php deleted file mode 100644 index 9c8093ac7295..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateDataExchangeRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.UpdateDataExchangeRequest - */ -class UpdateDataExchangeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_exchange = null; - - /** - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange Required. The data exchange to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateDataExchangeRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $dataExchange, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDataExchange($dataExchange) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $data_exchange - * Required. The data exchange to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange|null - */ - public function getDataExchange() - { - return $this->data_exchange; - } - - public function hasDataExchange() - { - return isset($this->data_exchange); - } - - public function clearDataExchange() - { - unset($this->data_exchange); - } - - /** - * Required. The data exchange to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.DataExchange data_exchange = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange $var - * @return $this - */ - public function setDataExchange($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange::class); - $this->data_exchange = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateListingRequest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateListingRequest.php deleted file mode 100644 index 65cdaa83e854..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/proto/src/Google/Cloud/BigQuery/DataExchange/V1beta1/UpdateListingRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.bigquery.dataexchange.v1beta1.UpdateListingRequest - */ -class UpdateListingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $listing = null; - - /** - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing Required. The listing to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\UpdateListingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setListing($listing) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * @type \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $listing - * Required. The listing to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Dataexchange\V1Beta1\Dataexchange::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing|null - */ - public function getListing() - { - return $this->listing; - } - - public function hasListing() - { - return isset($this->listing); - } - - public function clearListing() - { - unset($this->listing); - } - - /** - * Required. The listing to update. - * - * Generated from protobuf field .google.cloud.bigquery.dataexchange.v1beta1.Listing listing = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing $var - * @return $this - */ - public function setListing($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing::class); - $this->listing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php deleted file mode 100644 index 9a3fb8952b4d..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_data_exchange.php +++ /dev/null @@ -1,91 +0,0 @@ -setDisplayName($dataExchangeDisplayName); - $request = (new CreateDataExchangeRequest()) - ->setParent($formattedParent) - ->setDataExchangeId($dataExchangeId) - ->setDataExchange($dataExchange); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->createDataExchange($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 = AnalyticsHubServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = '[DATA_EXCHANGE_ID]'; - $dataExchangeDisplayName = '[DISPLAY_NAME]'; - - create_data_exchange_sample($formattedParent, $dataExchangeId, $dataExchangeDisplayName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_CreateDataExchange_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php deleted file mode 100644 index 4c4dc82b740e..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/create_listing.php +++ /dev/null @@ -1,98 +0,0 @@ -setBigqueryDataset($listingBigqueryDataset) - ->setDisplayName($listingDisplayName); - $request = (new CreateListingRequest()) - ->setParent($formattedParent) - ->setListingId($listingId) - ->setListing($listing); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->createListing($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - $listingId = '[LISTING_ID]'; - $listingDisplayName = '[DISPLAY_NAME]'; - - create_listing_sample($formattedParent, $listingId, $listingDisplayName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_CreateListing_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php deleted file mode 100644 index d0cfb1fe8211..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_data_exchange.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $analyticsHubServiceClient->deleteDataExchange($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - delete_data_exchange_sample($formattedName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_DeleteDataExchange_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php deleted file mode 100644 index d5b64cbb9800..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/delete_listing.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $analyticsHubServiceClient->deleteListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - delete_listing_sample($formattedName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_DeleteListing_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php deleted file mode 100644 index b84fa6d2dbc7..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_data_exchange.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->getDataExchange($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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - get_data_exchange_sample($formattedName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_GetDataExchange_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php deleted file mode 100644 index 2357182fde58..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_iam_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php deleted file mode 100644 index fdb99dd65688..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_listing.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->getListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - get_listing_sample($formattedName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_GetListing_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_location.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_location.php deleted file mode 100644 index edc703a1fa8b..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_GetLocation_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php deleted file mode 100644 index 2fd24e1d94f2..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_data_exchanges.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listDataExchanges($request); - - /** @var DataExchange $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 = AnalyticsHubServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_data_exchanges_sample($formattedParent); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_ListDataExchanges_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php deleted file mode 100644 index d7cb23c23045..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_listings.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listListings($request); - - /** @var Listing $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 = AnalyticsHubServiceClient::dataExchangeName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]' - ); - - list_listings_sample($formattedParent); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_ListListings_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php deleted file mode 100644 index 6bb5abf8fd77..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_ListLocations_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php deleted file mode 100644 index 8098681e9aac..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/list_org_data_exchanges.php +++ /dev/null @@ -1,77 +0,0 @@ -setOrganization($organization); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $analyticsHubServiceClient->listOrgDataExchanges($request); - - /** @var DataExchange $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 -{ - $organization = '[ORGANIZATION]'; - - list_org_data_exchanges_sample($organization); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_ListOrgDataExchanges_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php deleted file mode 100644 index c3c7b33e5104..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php deleted file mode 100644 index 4ae58653b402..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/subscribe_listing.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var SubscribeListingResponse $response */ - $response = $analyticsHubServiceClient->subscribeListing($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 = AnalyticsHubServiceClient::listingName( - '[PROJECT]', - '[LOCATION]', - '[DATA_EXCHANGE]', - '[LISTING]' - ); - - subscribe_listing_sample($formattedName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_SubscribeListing_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php deleted file mode 100644 index ab83337f997f..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,78 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $analyticsHubServiceClient->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); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php deleted file mode 100644 index 2bf640e0948d..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_data_exchange.php +++ /dev/null @@ -1,79 +0,0 @@ -setDisplayName($dataExchangeDisplayName); - $request = (new UpdateDataExchangeRequest()) - ->setUpdateMask($updateMask) - ->setDataExchange($dataExchange); - - // Call the API and handle any network failures. - try { - /** @var DataExchange $response */ - $response = $analyticsHubServiceClient->updateDataExchange($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 -{ - $dataExchangeDisplayName = '[DISPLAY_NAME]'; - - update_data_exchange_sample($dataExchangeDisplayName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_UpdateDataExchange_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php deleted file mode 100644 index 3a5c37c4afc2..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/samples/V1beta1/AnalyticsHubServiceClient/update_listing.php +++ /dev/null @@ -1,82 +0,0 @@ -setBigqueryDataset($listingBigqueryDataset) - ->setDisplayName($listingDisplayName); - $request = (new UpdateListingRequest()) - ->setUpdateMask($updateMask) - ->setListing($listing); - - // Call the API and handle any network failures. - try { - /** @var Listing $response */ - $response = $analyticsHubServiceClient->updateListing($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 -{ - $listingDisplayName = '[DISPLAY_NAME]'; - - update_listing_sample($listingDisplayName); -} -// [END analyticshub_v1beta1_generated_AnalyticsHubService_UpdateListing_sync] diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/AnalyticsHubServiceClient.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/AnalyticsHubServiceClient.php deleted file mode 100644 index d039b6da3174..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/AnalyticsHubServiceClient.php +++ /dev/null @@ -1,36 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $dataExchangeId = 'data_exchange_id'; - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * 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. - * - * @experimental - */ -class AnalyticsHubServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'analyticshub.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/bigquery', - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $dataExchangeNameTemplate; - - private static $datasetNameTemplate; - - private static $listingNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/analytics_hub_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/analytics_hub_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/analytics_hub_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/analytics_hub_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getDataExchangeNameTemplate() - { - if (self::$dataExchangeNameTemplate == null) { - self::$dataExchangeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataExchanges/{data_exchange}'); - } - - return self::$dataExchangeNameTemplate; - } - - private static function getDatasetNameTemplate() - { - if (self::$datasetNameTemplate == null) { - self::$datasetNameTemplate = new PathTemplate('projects/{project}/datasets/{dataset}'); - } - - return self::$datasetNameTemplate; - } - - private static function getListingNameTemplate() - { - if (self::$listingNameTemplate == null) { - self::$listingNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}'); - } - - return self::$listingNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'dataExchange' => self::getDataExchangeNameTemplate(), - 'dataset' => self::getDatasetNameTemplate(), - 'listing' => self::getListingNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * data_exchange resource. - * - * @param string $project - * @param string $location - * @param string $dataExchange - * - * @return string The formatted data_exchange resource. - * - * @experimental - */ - public static function dataExchangeName($project, $location, $dataExchange) - { - return self::getDataExchangeNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_exchange' => $dataExchange, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dataset - * resource. - * - * @param string $project - * @param string $dataset - * - * @return string The formatted dataset resource. - * - * @experimental - */ - public static function datasetName($project, $dataset) - { - return self::getDatasetNameTemplate()->render([ - 'project' => $project, - 'dataset' => $dataset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a listing - * resource. - * - * @param string $project - * @param string $location - * @param string $dataExchange - * @param string $listing - * - * @return string The formatted listing resource. - * - * @experimental - */ - public static function listingName($project, $location, $dataExchange, $listing) - { - return self::getListingNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_exchange' => $dataExchange, - 'listing' => $listing, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - * - * @experimental - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - dataExchange: projects/{project}/locations/{location}/dataExchanges/{data_exchange} - * - dataset: projects/{project}/datasets/{dataset} - * - listing: projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticshub.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a new data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $dataExchangeId = 'data_exchange_id'; - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the data exchange. - * e.g. `projects/myproject/locations/US`. - * @param string $dataExchangeId Required. The ID of the data exchange. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @param DataExchange $dataExchange Required. The data exchange to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createDataExchange($parent, $dataExchangeId, $dataExchange, array $optionalArgs = []) - { - $request = new CreateDataExchangeRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDataExchangeId($dataExchangeId); - $request->setDataExchange($dataExchange); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $listingId = 'listing_id'; - * $listing = new Listing(); - * $response = $analyticsHubServiceClient->createListing($formattedParent, $listingId, $listing); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param string $listingId Required. The ID of the listing to create. - * Must contain only Unicode letters, numbers (0-9), underscores (_). - * Should not use characters that require URL-escaping, or characters - * outside of ASCII, spaces. - * Max length: 100 bytes. - * @param Listing $listing Required. The listing to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createListing($parent, $listingId, $listing, array $optionalArgs = []) - { - $request = new CreateListingRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setListingId($listingId); - $request->setListing($listing); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateListing', Listing::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes an existing data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $analyticsHubServiceClient->deleteDataExchange($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The full name of the data exchange resource that you want to delete. - * For example, `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function deleteDataExchange($name, array $optionalArgs = []) - { - $request = new DeleteDataExchangeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteDataExchange', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $analyticsHubServiceClient->deleteListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the listing to delete. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function deleteListing($name, array $optionalArgs = []) - { - $request = new DeleteListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteListing', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of a data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * $response = $analyticsHubServiceClient->getDataExchange($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the data exchange. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getDataExchange($name, array $optionalArgs = []) - { - $request = new GetDataExchangeRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the IAM policy. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $response = $analyticsHubServiceClient->getIamPolicy($resource); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of a listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $response = $analyticsHubServiceClient->getListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getListing($name, array $optionalArgs = []) - { - $request = new GetListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetListing', Listing::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists all data exchanges in a given project and location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listDataExchanges($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listDataExchanges($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the data exchanges. - * e.g. `projects/myproject/locations/US`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listDataExchanges($parent, array $optionalArgs = []) - { - $request = new ListDataExchangesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDataExchanges', $optionalArgs, ListDataExchangesResponse::class, $request); - } - - /** - * Lists all listings in a given project and location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedParent = $analyticsHubServiceClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listListings($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listListings($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource path of the listing. - * e.g. `projects/myproject/locations/US/dataExchanges/123`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listListings($parent, array $optionalArgs = []) - { - $request = new ListListingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListListings', $optionalArgs, ListListingsResponse::class, $request); - } - - /** - * Lists all data exchanges from projects in a given organization and - * location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $organization = 'organization'; - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listOrgDataExchanges($organization); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listOrgDataExchanges($organization); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $organization Required. The organization resource path of the projects containing DataExchanges. - * e.g. `organizations/myorg/locations/US`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listOrgDataExchanges($organization, array $optionalArgs = []) - { - $request = new ListOrgDataExchangesRequest(); - $requestParamHeaders = []; - $request->setOrganization($organization); - $requestParamHeaders['organization'] = $organization; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListOrgDataExchanges', $optionalArgs, ListOrgDataExchangesResponse::class, $request); - } - - /** - * Sets the IAM policy. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $analyticsHubServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Subscribes to a listing. - * - * Currently, with Analytics Hub, you can create listings that - * reference only BigQuery datasets. - * Upon subscription to a listing for a BigQuery dataset, Analytics Hub - * creates a linked dataset in the subscriber's project. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $formattedName = $analyticsHubServiceClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - * $response = $analyticsHubServiceClient->subscribeListing($formattedName); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the listing that you want to subscribe to. - * e.g. `projects/myproject/locations/US/dataExchanges/123/listings/456`. - * @param array $optionalArgs { - * Optional. - * - * @type DestinationDataset $destinationDataset - * BigQuery destination dataset to create for the subscriber. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function subscribeListing($name, array $optionalArgs = []) - { - $request = new SubscribeListingRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['destinationDataset'])) { - $request->setDestinationDataset($optionalArgs['destinationDataset']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SubscribeListing', SubscribeListingResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the permissions that a caller has. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $analyticsHubServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an existing data exchange. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $dataExchange = new DataExchange(); - * $response = $analyticsHubServiceClient->updateDataExchange($updateMask, $dataExchange); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Field mask specifies the fields to update in the data exchange - * resource. The fields specified in the - * `updateMask` are relative to the resource and are not a full request. - * @param DataExchange $dataExchange Required. The data exchange to update. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateDataExchange($updateMask, $dataExchange, array $optionalArgs = []) - { - $request = new UpdateDataExchangeRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setDataExchange($dataExchange); - $requestParamHeaders['data_exchange.name'] = $dataExchange->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateDataExchange', DataExchange::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an existing listing. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $updateMask = new FieldMask(); - * $listing = new Listing(); - * $response = $analyticsHubServiceClient->updateListing($updateMask, $listing); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param FieldMask $updateMask Required. Field mask specifies the fields to update in the listing resource. The - * fields specified in the `updateMask` are relative to the resource and are - * not a full request. - * @param Listing $listing Required. The listing to update. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataExchange\V1beta1\Listing - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateListing($updateMask, $listing, array $optionalArgs = []) - { - $request = new UpdateListingRequest(); - $requestParamHeaders = []; - $request->setUpdateMask($updateMask); - $request->setListing($listing); - $requestParamHeaders['listing.name'] = $listing->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateListing', Listing::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * $response = $analyticsHubServiceClient->getLocation(); - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $analyticsHubServiceClient = new AnalyticsHubServiceClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $analyticsHubServiceClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $analyticsHubServiceClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $analyticsHubServiceClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } -} diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/gapic_metadata.json b/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/gapic_metadata.json deleted file mode 100644 index f0e891ccec84..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/gapic_metadata.json +++ /dev/null @@ -1,103 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.bigquery.dataexchange.v1beta1", - "libraryPackage": "Google\\Cloud\\BigQuery\\DataExchange\\V1beta1", - "services": { - "AnalyticsHubService": { - "clients": { - "grpc": { - "libraryClient": "AnalyticsHubServiceGapicClient", - "rpcs": { - "CreateDataExchange": { - "methods": [ - "createDataExchange" - ] - }, - "CreateListing": { - "methods": [ - "createListing" - ] - }, - "DeleteDataExchange": { - "methods": [ - "deleteDataExchange" - ] - }, - "DeleteListing": { - "methods": [ - "deleteListing" - ] - }, - "GetDataExchange": { - "methods": [ - "getDataExchange" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "GetListing": { - "methods": [ - "getListing" - ] - }, - "ListDataExchanges": { - "methods": [ - "listDataExchanges" - ] - }, - "ListListings": { - "methods": [ - "listListings" - ] - }, - "ListOrgDataExchanges": { - "methods": [ - "listOrgDataExchanges" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "SubscribeListing": { - "methods": [ - "subscribeListing" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - }, - "UpdateDataExchange": { - "methods": [ - "updateDataExchange" - ] - }, - "UpdateListing": { - "methods": [ - "updateListing" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_client_config.json b/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_client_config.json deleted file mode 100644 index ef5607e7a3c2..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_client_config.json +++ /dev/null @@ -1,120 +0,0 @@ -{ - "interfaces": { - "google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "DEADLINE_EXCEEDED", - "UNAVAILABLE" - ] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDataExchanges": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListListings": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListOrgDataExchanges": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SubscribeListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDataExchange": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateListing": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_descriptor_config.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_descriptor_config.php deleted file mode 100644 index 483a7d7da69f..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_descriptor_config.php +++ /dev/null @@ -1,254 +0,0 @@ - [ - 'google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService' => [ - 'CreateDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'GetListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListDataExchanges' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataExchanges', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListDataExchangesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListListings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListings', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListListingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListOrgDataExchanges' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataExchanges', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\ListOrgDataExchangesResponse', - 'headerParams' => [ - [ - 'keyName' => 'organization', - 'fieldAccessors' => [ - 'getOrganization', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'SubscribeListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\SubscribeListingResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataExchange' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\DataExchange', - 'headerParams' => [ - [ - 'keyName' => 'data_exchange.name', - 'fieldAccessors' => [ - 'getDataExchange', - 'getName', - ], - ], - ], - ], - 'UpdateListing' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataExchange\V1beta1\Listing', - 'headerParams' => [ - [ - 'keyName' => 'listing.name', - 'fieldAccessors' => [ - 'getListing', - 'getName', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'templateMap' => [ - 'dataExchange' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}', - 'dataset' => 'projects/{project}/datasets/{dataset}', - 'listing' => 'projects/{project}/locations/{location}/dataExchanges/{data_exchange}/listings/{listing}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_rest_client_config.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_rest_client_config.php deleted file mode 100644 index b8d0e8344dab..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/src/V1beta1/resources/analytics_hub_service_rest_client_config.php +++ /dev/null @@ -1,240 +0,0 @@ - [ - 'google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService' => [ - 'CreateDataExchange' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*}/dataExchanges', - 'body' => 'data_exchange', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'data_exchange_id', - ], - ], - 'CreateListing' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*/dataExchanges/*}/listings', - 'body' => 'listing', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'listing_id', - ], - ], - 'DeleteDataExchange' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataExchanges/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteListing' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDataExchange' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataExchanges/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*}:getIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:getIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'GetListing' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListDataExchanges' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*}/dataExchanges', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListListings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*/dataExchanges/*}/listings', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListOrgDataExchanges' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{organization=organizations/*/locations/*}/dataExchanges', - 'placeholders' => [ - 'organization' => [ - 'getters' => [ - 'getOrganization', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SubscribeListing' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataExchanges/*/listings/*}:subscribe', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataExchanges/*/listings/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataExchange' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1beta1/{data_exchange.name=projects/*/locations/*/dataExchanges/*}', - 'body' => 'data_exchange', - 'placeholders' => [ - 'data_exchange.name' => [ - 'getters' => [ - 'getDataExchange', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateListing' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1beta1/{listing.name=projects/*/locations/*/dataExchanges/*/listings/*}', - 'body' => 'listing', - 'placeholders' => [ - 'listing.name' => [ - 'getters' => [ - 'getListing', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/AnalyticsHubServiceClientTest.php b/owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/AnalyticsHubServiceClientTest.php deleted file mode 100644 index 7790db0accb2..000000000000 --- a/owl-bot-staging/BigQueryDataExchange/v1beta1/tests/Unit/V1beta1/AnalyticsHubServiceClientTest.php +++ /dev/null @@ -1,1239 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AnalyticsHubServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AnalyticsHubServiceClient($options); - } - - /** @test */ - public function createDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = 'dataExchangeId1402219426'; - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - $response = $gapicClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/CreateDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDataExchangeId(); - $this->assertProtobufEquals($dataExchangeId, $actualValue); - $actualValue = $actualRequestObject->getDataExchange(); - $this->assertProtobufEquals($dataExchange, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataExchangeId = 'dataExchangeId1402219426'; - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - try { - $gapicClient->createDataExchange($formattedParent, $dataExchangeId, $dataExchange); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $listingId = 'listingId988969142'; - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - $response = $gapicClient->createListing($formattedParent, $listingId, $listing); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/CreateListing', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getListingId(); - $this->assertProtobufEquals($listingId, $actualValue); - $actualValue = $actualRequestObject->getListing(); - $this->assertProtobufEquals($listing, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $listingId = 'listingId988969142'; - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - try { - $gapicClient->createListing($formattedParent, $listingId, $listing); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $gapicClient->deleteDataExchange($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/DeleteDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->deleteDataExchange($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $gapicClient->deleteListing($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/DeleteListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->deleteListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $response = $gapicClient->getDataExchange($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->getDataExchange($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $response = $gapicClient->getListing($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/GetListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->getListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataExchangesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataExchangesElement = new DataExchange(); - $dataExchanges = [ - $dataExchangesElement, - ]; - $expectedResponse = new ListDataExchangesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataExchanges($dataExchanges); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDataExchanges($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataExchanges()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListDataExchanges', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataExchangesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDataExchanges($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listListingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $listingsElement = new Listing(); - $listings = [ - $listingsElement, - ]; - $expectedResponse = new ListListingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setListings($listings); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - $response = $gapicClient->listListings($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListings()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListListings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listListingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->dataExchangeName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]'); - try { - $gapicClient->listListings($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOrgDataExchangesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataExchangesElement = new DataExchange(); - $dataExchanges = [ - $dataExchangesElement, - ]; - $expectedResponse = new ListOrgDataExchangesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataExchanges($dataExchanges); - $transport->addResponse($expectedResponse); - // Mock request - $organization = 'organization1178922291'; - $response = $gapicClient->listOrgDataExchanges($organization); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataExchanges()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/ListOrgDataExchanges', $actualFuncCall); - $actualValue = $actualRequestObject->getOrganization(); - $this->assertProtobufEquals($organization, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listOrgDataExchangesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $organization = 'organization1178922291'; - try { - $gapicClient->listOrgDataExchanges($organization); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function subscribeListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new SubscribeListingResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - $response = $gapicClient->subscribeListing($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/SubscribeListing', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function subscribeListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->listingName('[PROJECT]', '[LOCATION]', '[DATA_EXCHANGE]', '[LISTING]'); - try { - $gapicClient->subscribeListing($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataExchangeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $listingCount = 1101038700; - $icon = '121'; - $expectedResponse = new DataExchange(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setListingCount($listingCount); - $expectedResponse->setIcon($icon); - $transport->addResponse($expectedResponse); - // Mock request - $updateMask = new FieldMask(); - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - $response = $gapicClient->updateDataExchange($updateMask, $dataExchange); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/UpdateDataExchange', $actualFuncCall); - $actualValue = $actualRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualRequestObject->getDataExchange(); - $this->assertProtobufEquals($dataExchange, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataExchangeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $dataExchange = new DataExchange(); - $dataExchangeDisplayName = 'dataExchangeDisplayName-1195270080'; - $dataExchange->setDisplayName($dataExchangeDisplayName); - try { - $gapicClient->updateDataExchange($updateMask, $dataExchange); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateListingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $primaryContact = 'primaryContact203339491'; - $documentation = 'documentation1587405498'; - $icon = '121'; - $requestAccess = 'requestAccess2059178260'; - $expectedResponse = new Listing(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setPrimaryContact($primaryContact); - $expectedResponse->setDocumentation($documentation); - $expectedResponse->setIcon($icon); - $expectedResponse->setRequestAccess($requestAccess); - $transport->addResponse($expectedResponse); - // Mock request - $updateMask = new FieldMask(); - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - $response = $gapicClient->updateListing($updateMask, $listing); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.dataexchange.v1beta1.AnalyticsHubService/UpdateListing', $actualFuncCall); - $actualValue = $actualRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualRequestObject->getListing(); - $this->assertProtobufEquals($listing, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateListingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $updateMask = new FieldMask(); - $listing = new Listing(); - $listingDisplayName = 'listingDisplayName293456201'; - $listing->setDisplayName($listingDisplayName); - $listingBigqueryDataset = new BigQueryDatasetSource(); - $listing->setBigqueryDataset($listingBigqueryDataset); - try { - $gapicClient->updateListing($updateMask, $listing); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1/Datapolicy.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1/Datapolicy.php deleted file mode 100644 index e7871c7a05ddfdedaf5892d544e3a3827f4d7c36..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5222 zcmcIo&2Jk;6tA7OkO@uFY1*U#(e2WzNtCWhfPywn!}=qMRVOjAlak12wYJC3()I4L zyH08%b3k0URYHRQ0r(e?IQIw=hj0PGsYi~Scr*LqwVgJ0T5^f)dGF2d{odEi++8yF zO!OAFLUdv&4k>fR2IuS%&a@22C>a`8tXC?;;z~x%R5fA=9GBeS);IE8Dw)n-2UXjs zTO}fLRl}%iBv#UldO229tDn`0)rgf9M==deEvdwg?a#HoHw3l?Lb_5TwyBf|w~~#o z5l5jag%xJ4kf7EIanD*I8M0Q`o?Aeuq$#$|1;01YA>!cAtQTQV&UO?B{@qY*S=CiX zRW$W;@Nto=D4I<`y<4_Y*GrCS=p0qp&`V@$nsaSZ*&C(-oGfxazAU8)C@Q3NhgiCz z6_Ug*S*qz6Ru)7>u}YkPT>8t@w6`rar&hQr7o#Y4fn4Mqt4_kZbDTw-x}`5L+|)ob z_*6KCJ;_uHlCB$+1w*$*vE@_C#IqC=no4x1Kb>WjXyrKBQ}$KE>Q8l(c!|_A$h1;} z94NrQEKRUR@B4Y0{i+4Q2C7pv)9GW!K$S7Hrq~aUN6Yf-_C3|hCaGKwl4lvpZz>2k z4gM|kJBRL^uI}(nS5IK|D){v(gzHto&f)3)+4;0Fge-2-nRC-x5l~$R9=kGNO*?*CKN2X$ZEj1E5ZL5 zLE{OFK&zuY!_9zA0=>$1a1xz26$@OPh;Wgq!T7s>NYQ^K0nhsE1mrXX7X`3l3(y*4 zEo1mT8lrNZM-x#nH8elxDV#vJ(6SRBfZh4;0PdCv_Ktzuu@S|5>Wy#=4b|B`G9}AH zJ?W$N`4ocm<=4>oCZWB%1=;8EB05VKJQk@R_!`1GIgmrd$ZDDGGUz(`2^voljU4A^ zyv>{!6x3Hx_+2!%LY!`>FT?h?5TlH0x2(gc^Qm|_DRmJIno5<(HcT%@+Bu97Vm~>? zL!wU%(0s+i=zK-hU=B^3rQi7`n&`%5n=lCoUPTvL!2rMztbtRd4<1J&I(g*CAviSW z2l=ngBGh6Wj{#!Vr)5W}x(HX#;0Ndu!$Gr7)vJEhoMXxSfuDcRZ&IvkXio(LZbh#~ za90uz;9WG@^0^^94bx?Fc>cpaHgb0eRcapW;45f2Y#WlB#e}b+;T8u>l0$DKrMx6( zH!|tOj-21grsS>lTsDKUTq?1(na=NcDx(9y`6Xs! zP0HO*udnzEQL+A1vid6x9Ealml$0DhcIbU-#x$ek9vNbX{>NsF`p2B7N4dk0x6Sw{ z8m=i$X^%!wQ;I~3zY4vSMVo&dMHeXrZ2`hMx@=mcOe(5Q$})KbUu+u=DXeJ>&#(0n zkT%0YHn5rsjIN&H>uBt_6?_w2&u*rYspa%~Dk-NvhA+8XdSksKBnX|)txEIn-2w7P z(2$gQAnoMj^{q^1^c=p5E`tGSE0dS~fNV>dt<>l%@iBz`%x?KO|9Hfu#7(6fvG&yx z!GA{3Xy<6c_j)9vQ_*Wcll>1Ke)r2?|NbVr#J^2v^PxKt7lS032_?r&ds2wu!FMEK zS9La&Dfl1ov2&jF>|>|m3;6hu`FMZ+F7q*jP@t3R8Q!*6z)Z8l-|>){+0Zb>e}U7T zv$AKWI~8BR=|X{deV2cqdEJkva4G^`#K_E%G)_Owc29Hs1Gw2a!+UnKQ_*+xil6_% z5rmz*`6cGc{EVBVeYkQYvBL@eIf5><9SQJ)ztsuTrcKMod5SvoT)?Mx;Wr?>bHMjZ zc&DQ8$Wo6ibnCk(3tn;~%czzFvkI)m1n_*e{1eA^JuDL4i#gJVJt44r^ zjShAoqK79y9DWLepUmO{ogTh~S^PeFbA>&D2?_cHCcqQeNAy8W2sQ>SVSDb0FIVv1 z%IISmlPs{;GKLXE3-DC(G&=3t6h&rK6hW3f(}`l(tSD~J70google.cloud.bigquery.datapolicies.v1.CreateDataPolicyRequest - */ -class CreateDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_policy = null; - - /** - * @param string $parent Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. Please see - * {@see DataPolicyServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\CreateDataPolicyRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy): self - { - return (new self()) - ->setParent($parent) - ->setDataPolicy($dataPolicy); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. - * @type \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $data_policy - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy|null - */ - public function getDataPolicy() - { - return $this->data_policy; - } - - public function hasDataPolicy() - { - return isset($this->data_policy); - } - - public function clearDataPolicy() - { - unset($this->data_policy); - } - - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $var - * @return $this - */ - public function setDataPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy::class); - $this->data_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy.php deleted file mode 100644 index 8ef0e8712da8..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy - */ -class DataMaskingPolicy extends \Google\Protobuf\Internal\Message -{ - protected $masking_expression; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $predefined_expression - * A predefined masking expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * A predefined masking expression. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy.PredefinedExpression predefined_expression = 1; - * @return int - */ - public function getPredefinedExpression() - { - return $this->readOneof(1); - } - - public function hasPredefinedExpression() - { - return $this->hasOneof(1); - } - - /** - * A predefined masking expression. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy.PredefinedExpression predefined_expression = 1; - * @param int $var - * @return $this - */ - public function setPredefinedExpression($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy\PredefinedExpression::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getMaskingExpression() - { - return $this->whichOneof("masking_expression"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy/PredefinedExpression.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy/PredefinedExpression.php deleted file mode 100644 index 60b9fd0a85e5..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy/PredefinedExpression.php +++ /dev/null @@ -1,89 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy.PredefinedExpression - */ -class PredefinedExpression -{ - /** - * Default, unspecified predefined expression. No masking will take place - * since no expression is specified. - * - * Generated from protobuf enum PREDEFINED_EXPRESSION_UNSPECIFIED = 0; - */ - const PREDEFINED_EXPRESSION_UNSPECIFIED = 0; - /** - * Masking expression to replace data with SHA-256 hash. - * - * Generated from protobuf enum SHA256 = 3; - */ - const SHA256 = 3; - /** - * Masking expression to replace data with NULLs. - * - * Generated from protobuf enum ALWAYS_NULL = 5; - */ - const ALWAYS_NULL = 5; - /** - * Masking expression to replace data with their default masking values. - * The default masking values for each type listed as below: - * * STRING: "" - * * BYTES: b'' - * * INTEGER: 0 - * * FLOAT: 0.0 - * * NUMERIC: 0 - * * BOOLEAN: FALSE - * * TIMESTAMP: 0001-01-01 00:00:00 UTC - * * DATE: 0001-01-01 - * * TIME: 00:00:00 - * * DATETIME: 0001-01-01T00:00:00 - * * GEOGRAPHY: POINT(0 0) - * * BIGNUMERIC: 0 - * * ARRAY: [] - * * STRUCT: NOT_APPLICABLE - * * JSON: NULL - * - * Generated from protobuf enum DEFAULT_MASKING_VALUE = 7; - */ - const DEFAULT_MASKING_VALUE = 7; - - private static $valueToName = [ - self::PREDEFINED_EXPRESSION_UNSPECIFIED => 'PREDEFINED_EXPRESSION_UNSPECIFIED', - self::SHA256 => 'SHA256', - self::ALWAYS_NULL => 'ALWAYS_NULL', - self::DEFAULT_MASKING_VALUE => 'DEFAULT_MASKING_VALUE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PredefinedExpression::class, \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy_PredefinedExpression::class); - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy_PredefinedExpression.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy_PredefinedExpression.php deleted file mode 100644 index 4e9534de50a3..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataMaskingPolicy_PredefinedExpression.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.DataPolicy - */ -class DataPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2; - */ - protected $data_policy_type = 0; - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - */ - protected $data_policy_id = ''; - protected $matching_label; - protected $policy; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $policy_tag - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * @type \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy $data_masking_policy - * The data masking policy that specifies the data masking rule to use. - * @type string $name - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @type int $data_policy_type - * Type of data policy. - * @type string $data_policy_id - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * - * Generated from protobuf field string policy_tag = 4; - * @return string - */ - public function getPolicyTag() - { - return $this->readOneof(4); - } - - public function hasPolicyTag() - { - return $this->hasOneof(4); - } - - /** - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * - * Generated from protobuf field string policy_tag = 4; - * @param string $var - * @return $this - */ - public function setPolicyTag($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * The data masking policy that specifies the data masking rule to use. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5; - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy|null - */ - public function getDataMaskingPolicy() - { - return $this->readOneof(5); - } - - public function hasDataMaskingPolicy() - { - return $this->hasOneof(5); - } - - /** - * The data masking policy that specifies the data masking rule to use. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5; - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy $var - * @return $this - */ - public function setDataMaskingPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1\DataMaskingPolicy::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2; - * @return int - */ - public function getDataPolicyType() - { - return $this->data_policy_type; - } - - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2; - * @param int $var - * @return $this - */ - public function setDataPolicyType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy\DataPolicyType::class); - $this->data_policy_type = $var; - - return $this; - } - - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - * @return string - */ - public function getDataPolicyId() - { - return $this->data_policy_id; - } - - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - * @param string $var - * @return $this - */ - public function setDataPolicyId($var) - { - GPBUtil::checkString($var, True); - $this->data_policy_id = $var; - - return $this; - } - - /** - * @return string - */ - public function getMatchingLabel() - { - return $this->whichOneof("matching_label"); - } - - /** - * @return string - */ - public function getPolicy() - { - return $this->whichOneof("policy"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy/DataPolicyType.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy/DataPolicyType.php deleted file mode 100644 index 0f431ea3e887..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy/DataPolicyType.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType - */ -class DataPolicyType -{ - /** - * Default value for the data policy type. This should not be used. - * - * Generated from protobuf enum DATA_POLICY_TYPE_UNSPECIFIED = 0; - */ - const DATA_POLICY_TYPE_UNSPECIFIED = 0; - /** - * Used to create a data policy for column-level security, without data - * masking. - * - * Generated from protobuf enum COLUMN_LEVEL_SECURITY_POLICY = 3; - */ - const COLUMN_LEVEL_SECURITY_POLICY = 3; - /** - * Used to create a data policy for data masking. - * - * Generated from protobuf enum DATA_MASKING_POLICY = 2; - */ - const DATA_MASKING_POLICY = 2; - - private static $valueToName = [ - self::DATA_POLICY_TYPE_UNSPECIFIED => 'DATA_POLICY_TYPE_UNSPECIFIED', - self::COLUMN_LEVEL_SECURITY_POLICY => 'COLUMN_LEVEL_SECURITY_POLICY', - self::DATA_MASKING_POLICY => 'DATA_MASKING_POLICY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DataPolicyType::class, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy_DataPolicyType::class); - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicyServiceGrpcClient.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicyServiceGrpcClient.php deleted file mode 100644 index 72ce620d4851..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicyServiceGrpcClient.php +++ /dev/null @@ -1,172 +0,0 @@ -_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/CreateDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * Updates the metadata for an existing data policy. The target data policy - * can be specified by the resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\UpdateDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1\UpdateDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/UpdateDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * Renames the id (display name) of the specified data policy. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\RenameDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RenameDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1\RenameDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/RenameDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * Deletes the data policy specified by its resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DeleteDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1\DeleteDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/DeleteDataPolicy', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Gets the data policy specified by its resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\GetDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1\GetDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/GetDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * List all of the data policies in the specified parent project. - * @param \Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListDataPolicies(\Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/ListDataPolicies', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the IAM policy for the specified data policy. - * @param \Google\Cloud\Iam\V1\GetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetIamPolicy(\Google\Cloud\Iam\V1\GetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/GetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Sets the IAM policy for the specified data policy. - * @param \Google\Cloud\Iam\V1\SetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SetIamPolicy(\Google\Cloud\Iam\V1\SetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/SetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Returns the caller's permission on the specified data policy resource. - * @param \Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TestIamPermissions(\Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/TestIamPermissions', - $argument, - ['\Google\Cloud\Iam\V1\TestIamPermissionsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy_DataPolicyType.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy_DataPolicyType.php deleted file mode 100644 index e853fdfb761b..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/DataPolicy_DataPolicyType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.DeleteDataPolicyRequest - */ -class DeleteDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. Please see - * {@see DataPolicyServiceClient::dataPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DeleteDataPolicyRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/GetDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/GetDataPolicyRequest.php deleted file mode 100644 index 8e6aa8262f60..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/GetDataPolicyRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.GetDataPolicyRequest - */ -class GetDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. Please see - * {@see DataPolicyServiceClient::dataPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\GetDataPolicyRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesRequest.php deleted file mode 100644 index 7672f31b0af3..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesRequest.php +++ /dev/null @@ -1,224 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.ListDataPoliciesRequest - */ -class ListDataPoliciesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filters the data policies by policy tags that they - * are associated with. Currently filter only supports - * "policy_tag" based filtering and OR based predicates. Sample - * filter can be "policy_tag: - * `'projects/1/locations/us/taxonomies/2/policyTags/3'`". You may use - * wildcard such as "policy_tag: - * `'projects/1/locations/us/taxonomies/2/*'`". - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. Please see - * {@see DataPolicyServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. - * @type int $page_size - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * @type string $page_token - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * @type string $filter - * Filters the data policies by policy tags that they - * are associated with. Currently filter only supports - * "policy_tag" based filtering and OR based predicates. Sample - * filter can be "policy_tag: - * `'projects/1/locations/us/taxonomies/2/policyTags/3'`". You may use - * wildcard such as "policy_tag: - * `'projects/1/locations/us/taxonomies/2/*'`". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filters the data policies by policy tags that they - * are associated with. Currently filter only supports - * "policy_tag" based filtering and OR based predicates. Sample - * filter can be "policy_tag: - * `'projects/1/locations/us/taxonomies/2/policyTags/3'`". You may use - * wildcard such as "policy_tag: - * `'projects/1/locations/us/taxonomies/2/*'`". - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filters the data policies by policy tags that they - * are associated with. Currently filter only supports - * "policy_tag" based filtering and OR based predicates. Sample - * filter can be "policy_tag: - * `'projects/1/locations/us/taxonomies/2/policyTags/3'`". You may use - * wildcard such as "policy_tag: - * `'projects/1/locations/us/taxonomies/2/*'`". - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesResponse.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesResponse.php deleted file mode 100644 index e23d7ae0d58e..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/ListDataPoliciesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.ListDataPoliciesResponse - */ -class ListDataPoliciesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policies = 1; - */ - private $data_policies; - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy>|\Google\Protobuf\Internal\RepeatedField $data_policies - * Data policies that belong to the requested project. - * @type string $next_page_token - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policies = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataPolicies() - { - return $this->data_policies; - } - - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policies = 1; - * @param array<\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy::class); - $this->data_policies = $arr; - - return $this; - } - - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/RenameDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/RenameDataPolicyRequest.php deleted file mode 100644 index cb59f030aab8..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/RenameDataPolicyRequest.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.RenameDataPolicyRequest - */ -class RenameDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Required. The new data policy id. - * - * Generated from protobuf field string new_data_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $new_data_policy_id = ''; - - /** - * @param string $name Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * @param string $newDataPolicyId Required. The new data policy id. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\RenameDataPolicyRequest - * - * @experimental - */ - public static function build(string $name, string $newDataPolicyId): self - { - return (new self()) - ->setName($name) - ->setNewDataPolicyId($newDataPolicyId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * @type string $new_data_policy_id - * Required. The new data policy id. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The new data policy id. - * - * Generated from protobuf field string new_data_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNewDataPolicyId() - { - return $this->new_data_policy_id; - } - - /** - * Required. The new data policy id. - * - * Generated from protobuf field string new_data_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNewDataPolicyId($var) - { - GPBUtil::checkString($var, True); - $this->new_data_policy_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/UpdateDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/UpdateDataPolicyRequest.php deleted file mode 100644 index 3bad7e59018b..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1/UpdateDataPolicyRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.bigquery.datapolicies.v1.UpdateDataPolicyRequest - */ -class UpdateDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_policy = null; - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy Required. Update the data policy's metadata. - * - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * @param \Google\Protobuf\FieldMask $updateMask The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\UpdateDataPolicyRequest - * - * @experimental - */ - public static function build(\Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $dataPolicy, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDataPolicy($dataPolicy) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $data_policy - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * @type \Google\Protobuf\FieldMask $update_mask - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy|null - */ - public function getDataPolicy() - { - return $this->data_policy; - } - - public function hasDataPolicy() - { - return isset($this->data_policy); - } - - public function clearDataPolicy() - { - unset($this->data_policy); - } - - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy $var - * @return $this - */ - public function setDataPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy::class); - $this->data_policy = $var; - - return $this; - } - - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/create_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/create_data_policy.php deleted file mode 100644 index 6bc9f8c5b836..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/create_data_policy.php +++ /dev/null @@ -1,75 +0,0 @@ -setParent($formattedParent) - ->setDataPolicy($dataPolicy); - - // Call the API and handle any network failures. - try { - /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->createDataPolicy($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 = DataPolicyServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - create_data_policy_sample($formattedParent); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_CreateDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/delete_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/delete_data_policy.php deleted file mode 100644 index cde24b2539d9..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/delete_data_policy.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dataPolicyServiceClient->deleteDataPolicy($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 = DataPolicyServiceClient::dataPolicyName( - '[PROJECT]', - '[LOCATION]', - '[DATA_POLICY]' - ); - - delete_data_policy_sample($formattedName); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_DeleteDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_data_policy.php deleted file mode 100644 index 21cade6321b8..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_data_policy.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->getDataPolicy($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 = DataPolicyServiceClient::dataPolicyName( - '[PROJECT]', - '[LOCATION]', - '[DATA_POLICY]' - ); - - get_data_policy_sample($formattedName); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_GetDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_iam_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_iam_policy.php deleted file mode 100644 index 4b12393582ea..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/get_iam_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $dataPolicyServiceClient->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); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/list_data_policies.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/list_data_policies.php deleted file mode 100644 index f7aecfb9f2b6..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/list_data_policies.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dataPolicyServiceClient->listDataPolicies($request); - - /** @var DataPolicy $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 = DataPolicyServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_data_policies_sample($formattedParent); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_ListDataPolicies_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/rename_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/rename_data_policy.php deleted file mode 100644 index 2834ec403527..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/rename_data_policy.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($name) - ->setNewDataPolicyId($newDataPolicyId); - - // Call the API and handle any network failures. - try { - /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->renameDataPolicy($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 -{ - $name = '[NAME]'; - $newDataPolicyId = '[NEW_DATA_POLICY_ID]'; - - rename_data_policy_sample($name, $newDataPolicyId); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_RenameDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/set_iam_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/set_iam_policy.php deleted file mode 100644 index 31d43f3228f7..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $dataPolicyServiceClient->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); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/test_iam_permissions.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/test_iam_permissions.php deleted file mode 100644 index 5f02eaf37971..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,78 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $dataPolicyServiceClient->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); -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/update_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/update_data_policy.php deleted file mode 100644 index 521e0623609a..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/samples/V1/DataPolicyServiceClient/update_data_policy.php +++ /dev/null @@ -1,60 +0,0 @@ -setDataPolicy($dataPolicy); - - // Call the API and handle any network failures. - try { - /** @var DataPolicy $response */ - $response = $dataPolicyServiceClient->updateDataPolicy($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END bigquerydatapolicy_v1_generated_DataPolicyService_UpdateDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/DataPolicyServiceClient.php b/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/DataPolicyServiceClient.php deleted file mode 100644 index e90871fd2b63..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/DataPolicyServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->createDataPolicy($formattedParent, $dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * 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. - */ -class DataPolicyServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.bigquery.datapolicies.v1.DataPolicyService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'bigquerydatapolicy.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/bigquery', - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $dataPolicyNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/data_policy_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/data_policy_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/data_policy_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/data_policy_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getDataPolicyNameTemplate() - { - if (self::$dataPolicyNameTemplate == null) { - self::$dataPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataPolicies/{data_policy}'); - } - - return self::$dataPolicyNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'dataPolicy' => self::getDataPolicyNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a data_policy - * resource. - * - * @param string $project - * @param string $location - * @param string $dataPolicy - * - * @return string The formatted data_policy resource. - */ - public static function dataPolicyName($project, $location, $dataPolicy) - { - return self::getDataPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_policy' => $dataPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - dataPolicy: projects/{project}/locations/{location}/dataPolicies/{data_policy} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'bigquerydatapolicy.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a new data policy under a project with the given `dataPolicyId` - * (used as the display name), policy tag, and data policy type. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedParent = $dataPolicyServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->createDataPolicy($formattedParent, $dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the project that the data policy will belong to. - * The format is `projects/{project_number}/locations/{location_id}`. - * @param DataPolicy $dataPolicy Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy - * - * @throws ApiException if the remote call fails - */ - public function createDataPolicy($parent, $dataPolicy, array $optionalArgs = []) - { - $request = new CreateDataPolicyRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDataPolicy($dataPolicy); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the data policy specified by its resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedName = $dataPolicyServiceClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - * $dataPolicyServiceClient->deleteDataPolicy($formattedName); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteDataPolicy($name, array $optionalArgs = []) - { - $request = new DeleteDataPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteDataPolicy', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the data policy specified by its resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedName = $dataPolicyServiceClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - * $response = $dataPolicyServiceClient->getDataPolicy($formattedName); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy - * - * @throws ApiException if the remote call fails - */ - public function getDataPolicy($name, array $optionalArgs = []) - { - $request = new GetDataPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the IAM policy for the specified data policy. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $response = $dataPolicyServiceClient->getIamPolicy($resource); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * List all of the data policies in the specified parent project. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedParent = $dataPolicyServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dataPolicyServiceClient->listDataPolicies($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dataPolicyServiceClient->listDataPolicies($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the project for which to list data policies. - * Format is `projects/{project_number}/locations/{location_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filters the data policies by policy tags that they - * are associated with. Currently filter only supports - * "policy_tag" based filtering and OR based predicates. Sample - * filter can be "policy_tag: - * `'projects/1/locations/us/taxonomies/2/policyTags/3'`". You may use - * wildcard such as "policy_tag: - * `'projects/1/locations/us/taxonomies/2/*'`". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listDataPolicies($parent, array $optionalArgs = []) - { - $request = new ListDataPoliciesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDataPolicies', $optionalArgs, ListDataPoliciesResponse::class, $request); - } - - /** - * Renames the id (display name) of the specified data policy. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $name = 'name'; - * $newDataPolicyId = 'new_data_policy_id'; - * $response = $dataPolicyServiceClient->renameDataPolicy($name, $newDataPolicyId); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the data policy to rename. The format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}` - * @param string $newDataPolicyId Required. The new data policy id. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy - * - * @throws ApiException if the remote call fails - */ - public function renameDataPolicy($name, $newDataPolicyId, array $optionalArgs = []) - { - $request = new RenameDataPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setNewDataPolicyId($newDataPolicyId); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RenameDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Sets the IAM policy for the specified data policy. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $dataPolicyServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the caller's permission on the specified data policy resource. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $dataPolicyServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the metadata for an existing data policy. The target data policy - * can be specified by the resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->updateDataPolicy($dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param DataPolicy $dataPolicy Required. Update the data policy's metadata. - * - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy - * - * @throws ApiException if the remote call fails - */ - public function updateDataPolicy($dataPolicy, array $optionalArgs = []) - { - $request = new UpdateDataPolicyRequest(); - $requestParamHeaders = []; - $request->setDataPolicy($dataPolicy); - $requestParamHeaders['data_policy.name'] = $dataPolicy->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/gapic_metadata.json b/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 1d84ac5f7a4d..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.bigquery.datapolicies.v1", - "libraryPackage": "Google\\Cloud\\BigQuery\\DataPolicies\\V1", - "services": { - "DataPolicyService": { - "clients": { - "grpc": { - "libraryClient": "DataPolicyServiceGapicClient", - "rpcs": { - "CreateDataPolicy": { - "methods": [ - "createDataPolicy" - ] - }, - "DeleteDataPolicy": { - "methods": [ - "deleteDataPolicy" - ] - }, - "GetDataPolicy": { - "methods": [ - "getDataPolicy" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "ListDataPolicies": { - "methods": [ - "listDataPolicies" - ] - }, - "RenameDataPolicy": { - "methods": [ - "renameDataPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - }, - "UpdateDataPolicy": { - "methods": [ - "updateDataPolicy" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_client_config.json b/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_client_config.json deleted file mode 100644 index c403ed0aa2f4..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_client_config.json +++ /dev/null @@ -1,79 +0,0 @@ -{ - "interfaces": { - "google.cloud.bigquery.datapolicies.v1.DataPolicyService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDataPolicies": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RenameDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_descriptor_config.php b/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_descriptor_config.php deleted file mode 100644 index cda5186072b8..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_descriptor_config.php +++ /dev/null @@ -1,129 +0,0 @@ - [ - 'google.cloud.bigquery.datapolicies.v1.DataPolicyService' => [ - 'CreateDataPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDataPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'ListDataPolicies' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataPolicies', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\ListDataPoliciesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'RenameDataPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\DataPolicies\V1\DataPolicy', - 'headerParams' => [ - [ - 'keyName' => 'data_policy.name', - 'fieldAccessors' => [ - 'getDataPolicy', - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'dataPolicy' => 'projects/{project}/locations/{location}/dataPolicies/{data_policy}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_rest_client_config.php b/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_rest_client_config.php deleted file mode 100644 index 0e1f8f6bdad2..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/src/V1/resources/data_policy_service_rest_client_config.php +++ /dev/null @@ -1,115 +0,0 @@ - [ - 'google.cloud.bigquery.datapolicies.v1.DataPolicyService' => [ - 'CreateDataPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dataPolicies', - 'body' => 'data_policy', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataPolicy' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDataPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataPolicies/*}:getIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'ListDataPolicies' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dataPolicies', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RenameDataPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dataPolicies/*}:rename', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataPolicies/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/dataPolicies/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataPolicy' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{data_policy.name=projects/*/locations/*/dataPolicies/*}', - 'body' => 'data_policy', - 'placeholders' => [ - 'data_policy.name' => [ - 'getters' => [ - 'getDataPolicy', - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/DataPolicyServiceClientTest.php b/owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/DataPolicyServiceClientTest.php deleted file mode 100644 index e8512fac8c89..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1/tests/Unit/V1/DataPolicyServiceClientTest.php +++ /dev/null @@ -1,644 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DataPolicyServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DataPolicyServiceClient($options); - } - - /** @test */ - public function createDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name = 'name3373707'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataPolicy = new DataPolicy(); - $response = $gapicClient->createDataPolicy($formattedParent, $dataPolicy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/CreateDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDataPolicy(); - $this->assertProtobufEquals($dataPolicy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataPolicy = new DataPolicy(); - try { - $gapicClient->createDataPolicy($formattedParent, $dataPolicy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - $gapicClient->deleteDataPolicy($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/DeleteDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - try { - $gapicClient->deleteDataPolicy($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name2 = 'name2-1052831874'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name2); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - $response = $gapicClient->getDataPolicy($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/GetDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - try { - $gapicClient->getDataPolicy($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataPoliciesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataPoliciesElement = new DataPolicy(); - $dataPolicies = [ - $dataPoliciesElement, - ]; - $expectedResponse = new ListDataPoliciesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataPolicies($dataPolicies); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDataPolicies($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataPolicies()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/ListDataPolicies', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataPoliciesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDataPolicies($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function renameDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name2 = 'name2-1052831874'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name2); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $newDataPolicyId = 'newDataPolicyId-1742039694'; - $response = $gapicClient->renameDataPolicy($name, $newDataPolicyId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/RenameDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $actualValue = $actualRequestObject->getNewDataPolicyId(); - $this->assertProtobufEquals($newDataPolicyId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function renameDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - $newDataPolicyId = 'newDataPolicyId-1742039694'; - try { - $gapicClient->renameDataPolicy($name, $newDataPolicyId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name = 'name3373707'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $dataPolicy = new DataPolicy(); - $response = $gapicClient->updateDataPolicy($dataPolicy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1.DataPolicyService/UpdateDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getDataPolicy(); - $this->assertProtobufEquals($dataPolicy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $dataPolicy = new DataPolicy(); - try { - $gapicClient->updateDataPolicy($dataPolicy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1Beta1/Datapolicy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/GPBMetadata/Google/Cloud/Bigquery/Datapolicies/V1Beta1/Datapolicy.php deleted file mode 100644 index 033323dc833b5bdd238ac2d3acb88c434baa33e6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5058 zcmcIo&2!sC6tA7O&<#!8ZQ7)Pp{gj;G?U8HK+B9m0NGX&Po2b#otAXOXk>fsh{}?X z5T#F-1cU42-#)2WpdUuAyaD; z*VgKUTP^3-L5S)ptIVX5rzVwLU{Wc>Oe%M-=cvgggzARox?Hr_MSF;YkKL)k?wsps z9(-NaT~#-APuC3nbMSVVYifo|Kz&%Y*)i*$ZkZfa*fi^8?keZoq_UT73)oraLXc%j z7?7nDO^-OHW+(;X)*apUET;^jqSzu{L^FLdcQx3Sn$w%yoR3iyhd?fKp3@=m-8s%7 zUdJ()7;b7{Kl-H{K%r#oie#D=Wx+CCQSABDGx0pdyrC1*OQy4;6QhwMyV?WYa+0ZT zkszf;23geFkO&HVm1(MVN8c~dOsWp7swwGYXNR=_PuDSOQM$7W++6Q`&O;V!~ zCC>^J;#?GN8vHBh$BSs`2o;FuePw}_uMn265HDXLDBs!XU?a`eq1nMF}Bd8 z382=33euLou_>~_FqmmoI$5-twmH9jv&V635*e9k38!>F=xhTs_~CgXl59QYeWAgcpaVY zWfUL;I>!zlWju{0P4dW7V<2dfp5nhgj!=(hJOwyei&Z_XHFKPbtR2IOg3dBDG&^*& z73TQ~mU+uzo{Z32Sf10S2v+<;Tub3IeHjDkKZaG5>ABxky{_#uIk6}w-Ob-7R$x^y zhR>sk_y&3-2ud4G^ypxc9D1W5RVB5&St{mt)ap)IR<}1QWjSA5DawV+F$@y<&C>Sz zhFX&E$R)KR=eM_t)tx{kGY0gZWj5BO%B|wYYPgUVJI^F1S#97Pl;fwQ?z!2$;MacE zu+lzU-pUa?$w&vA$X)Fz`MvUC6&<9!I`ES$c45gqiO4vo` zY=<;RQ#VONC6C~b>%vuomHEWtR??{SSr^KYX*sgIc8u?!se@MV+vrkxOD@PO#SOWj z${)j@N~O5DF%TDoPFB{W#Tz#v0+VQ5D&3WKD(c2|sgyZ^FQ9W^K-w-<)i5e|q|&yW zc_lZ6aG2;lM;HG+?epU2Q-wGW^g6+Rr%-0_Y{B^?Yz%4#y=eB3#|N)I{{7Ey(gprT zbRFOGPq^hMapq$QGvA*mV*DU`Dq&xBA(lP(%QVUi9!<$y9@IXn%QkblyeRctjsX_v zar7ML`-^0Lf583en3;vx35kD(un!)9$v7C)4mmg<=1z3#vI{6*U_QP#9}8;&zn)6$ zP{zNe(CNOD6@L`&H%j;JQw z_cB2_K9z#&DTWK-Ye0YW4uts-9$cm2>Mq0=Ll@2s$oRdBzs)e+;#Ye065iHFt&>&^ zikO;b@G7xqL-68@|35r828F`=C53Pm?)#KJ;%zp7iy7a==lHa7eyPjveVmABm;lluR^vVmiy0_))`7cxKMXF^*kXS!v7ZG}C0oX$$C3tSv zmS|rN#q8P->G@SQN)qyPlqA3?={B8C3DNGLB?P0SC!w$s44&xZiHR$0^u*ADyaFQ! zHqLsM7JTcX$jpl(D6r|5D8@Gs#XzBUlJ)L)u0-$f3;uv7HV=C4EQm?^Gn;+1kI;WR CKH5D1 diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/CreateDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/CreateDataPolicyRequest.php deleted file mode 100644 index d24912213cd4..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/CreateDataPolicyRequest.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.CreateDataPolicyRequest - */ -class CreateDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project that the data policy will belong to. The - * format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_policy = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the project that the data policy will belong to. The - * format is `projects/{project_number}/locations/{location_id}`. - * @type \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy $data_policy - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project that the data policy will belong to. The - * format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the project that the data policy will belong to. The - * format is `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy|null - */ - public function getDataPolicy() - { - return $this->data_policy; - } - - public function hasDataPolicy() - { - return isset($this->data_policy); - } - - public function clearDataPolicy() - { - unset($this->data_policy); - } - - /** - * Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy $var - * @return $this - */ - public function setDataPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy::class); - $this->data_policy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy.php deleted file mode 100644 index 235c59c6fad0..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy - */ -class DataMaskingPolicy extends \Google\Protobuf\Internal\Message -{ - protected $masking_expression; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $predefined_expression - * A predefined masking expression. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * A predefined masking expression. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy.PredefinedExpression predefined_expression = 1; - * @return int - */ - public function getPredefinedExpression() - { - return $this->readOneof(1); - } - - public function hasPredefinedExpression() - { - return $this->hasOneof(1); - } - - /** - * A predefined masking expression. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy.PredefinedExpression predefined_expression = 1; - * @param int $var - * @return $this - */ - public function setPredefinedExpression($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy\PredefinedExpression::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getMaskingExpression() - { - return $this->whichOneof("masking_expression"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy/PredefinedExpression.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy/PredefinedExpression.php deleted file mode 100644 index c312974013d2..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy/PredefinedExpression.php +++ /dev/null @@ -1,89 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy.PredefinedExpression - */ -class PredefinedExpression -{ - /** - * Default, unspecified predefined expression. No masking will take place - * since no expression is specified. - * - * Generated from protobuf enum PREDEFINED_EXPRESSION_UNSPECIFIED = 0; - */ - const PREDEFINED_EXPRESSION_UNSPECIFIED = 0; - /** - * Masking expression to replace data with SHA-256 hash. - * - * Generated from protobuf enum SHA256 = 3; - */ - const SHA256 = 3; - /** - * Masking expression to replace data with NULLs. - * - * Generated from protobuf enum ALWAYS_NULL = 5; - */ - const ALWAYS_NULL = 5; - /** - * Masking expression to replace data with their default masking values. - * The default masking values for each type listed as below: - * * STRING: "" - * * BYTES: b'' - * * INTEGER: 0 - * * FLOAT: 0.0 - * * NUMERIC: 0 - * * BOOLEAN: FALSE - * * TIMESTAMP: 0001-01-01 00:00:00 UTC - * * DATE: 0001-01-01 - * * TIME: 00:00:00 - * * DATETIME: 0001-01-01T00:00:00 - * * GEOGRAPHY: POINT(0 0) - * * BIGNUMERIC: 0 - * * ARRAY: [] - * * STRUCT: NOT_APPLICABLE - * * JSON: NULL - * - * Generated from protobuf enum DEFAULT_MASKING_VALUE = 7; - */ - const DEFAULT_MASKING_VALUE = 7; - - private static $valueToName = [ - self::PREDEFINED_EXPRESSION_UNSPECIFIED => 'PREDEFINED_EXPRESSION_UNSPECIFIED', - self::SHA256 => 'SHA256', - self::ALWAYS_NULL => 'ALWAYS_NULL', - self::DEFAULT_MASKING_VALUE => 'DEFAULT_MASKING_VALUE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PredefinedExpression::class, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy_PredefinedExpression::class); - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy_PredefinedExpression.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy_PredefinedExpression.php deleted file mode 100644 index e0a28838a415..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataMaskingPolicy_PredefinedExpression.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.DataPolicy - */ -class DataPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy.DataPolicyType data_policy_type = 2; - */ - protected $data_policy_type = 0; - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - */ - protected $data_policy_id = ''; - protected $matching_label; - protected $policy; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $policy_tag - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * @type \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy $data_masking_policy - * The data masking policy that specifies the data masking rule to use. - * @type string $name - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @type int $data_policy_type - * Type of data policy. - * @type string $data_policy_id - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * - * Generated from protobuf field string policy_tag = 4; - * @return string - */ - public function getPolicyTag() - { - return $this->readOneof(4); - } - - public function hasPolicyTag() - { - return $this->hasOneof(4); - } - - /** - * Policy tag resource name, in the format of - * `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`. - * - * Generated from protobuf field string policy_tag = 4; - * @param string $var - * @return $this - */ - public function setPolicyTag($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * The data masking policy that specifies the data masking rule to use. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy data_masking_policy = 5; - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy|null - */ - public function getDataMaskingPolicy() - { - return $this->readOneof(5); - } - - public function hasDataMaskingPolicy() - { - return $this->hasOneof(5); - } - - /** - * The data masking policy that specifies the data masking rule to use. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataMaskingPolicy data_masking_policy = 5; - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy $var - * @return $this - */ - public function setDataMaskingPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataMaskingPolicy::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Resource name of this data policy, in the format of - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy.DataPolicyType data_policy_type = 2; - * @return int - */ - public function getDataPolicyType() - { - return $this->data_policy_type; - } - - /** - * Type of data policy. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy.DataPolicyType data_policy_type = 2; - * @param int $var - * @return $this - */ - public function setDataPolicyType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy\DataPolicyType::class); - $this->data_policy_type = $var; - - return $this; - } - - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - * @return string - */ - public function getDataPolicyId() - { - return $this->data_policy_id; - } - - /** - * User-assigned (human readable) ID of the data policy that needs to be - * unique within a project. Used as {data_policy_id} in part of the resource - * name. - * - * Generated from protobuf field string data_policy_id = 3; - * @param string $var - * @return $this - */ - public function setDataPolicyId($var) - { - GPBUtil::checkString($var, True); - $this->data_policy_id = $var; - - return $this; - } - - /** - * @return string - */ - public function getMatchingLabel() - { - return $this->whichOneof("matching_label"); - } - - /** - * @return string - */ - public function getPolicy() - { - return $this->whichOneof("policy"); - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy/DataPolicyType.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy/DataPolicyType.php deleted file mode 100644 index dfca4a7f0d37..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy/DataPolicyType.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.DataPolicy.DataPolicyType - */ -class DataPolicyType -{ - /** - * Default value for the data policy type. This should not be used. - * - * Generated from protobuf enum DATA_POLICY_TYPE_UNSPECIFIED = 0; - */ - const DATA_POLICY_TYPE_UNSPECIFIED = 0; - /** - * Used to create a data policy for column-level security, without data - * masking. - * - * Generated from protobuf enum COLUMN_LEVEL_SECURITY_POLICY = 3; - */ - const COLUMN_LEVEL_SECURITY_POLICY = 3; - /** - * Used to create a data policy for data masking. - * - * Generated from protobuf enum DATA_MASKING_POLICY = 2; - */ - const DATA_MASKING_POLICY = 2; - - private static $valueToName = [ - self::DATA_POLICY_TYPE_UNSPECIFIED => 'DATA_POLICY_TYPE_UNSPECIFIED', - self::COLUMN_LEVEL_SECURITY_POLICY => 'COLUMN_LEVEL_SECURITY_POLICY', - self::DATA_MASKING_POLICY => 'DATA_MASKING_POLICY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DataPolicyType::class, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy_DataPolicyType::class); - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicyServiceGrpcClient.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicyServiceGrpcClient.php deleted file mode 100644 index 8aaf57c6f7eb..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicyServiceGrpcClient.php +++ /dev/null @@ -1,157 +0,0 @@ -_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/CreateDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * Updates the metadata for an existing data policy. The target data policy - * can be specified by the resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\UpdateDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1beta1\UpdateDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/UpdateDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * Deletes the data policy specified by its resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\DeleteDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1beta1\DeleteDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/DeleteDataPolicy', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Gets the data policy specified by its resource name. - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\GetDataPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetDataPolicy(\Google\Cloud\BigQuery\DataPolicies\V1beta1\GetDataPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/GetDataPolicy', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy', 'decode'], - $metadata, $options); - } - - /** - * List all of the data policies in the specified parent project. - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\ListDataPoliciesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListDataPolicies(\Google\Cloud\BigQuery\DataPolicies\V1beta1\ListDataPoliciesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/ListDataPolicies', - $argument, - ['\Google\Cloud\BigQuery\DataPolicies\V1beta1\ListDataPoliciesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets the IAM policy for the specified data policy. - * @param \Google\Cloud\Iam\V1\GetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetIamPolicy(\Google\Cloud\Iam\V1\GetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/GetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Sets the IAM policy for the specified data policy. - * @param \Google\Cloud\Iam\V1\SetIamPolicyRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SetIamPolicy(\Google\Cloud\Iam\V1\SetIamPolicyRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/SetIamPolicy', - $argument, - ['\Google\Cloud\Iam\V1\Policy', 'decode'], - $metadata, $options); - } - - /** - * Returns the caller's permission on the specified data policy resource. - * @param \Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function TestIamPermissions(\Google\Cloud\Iam\V1\TestIamPermissionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/TestIamPermissions', - $argument, - ['\Google\Cloud\Iam\V1\TestIamPermissionsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy_DataPolicyType.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy_DataPolicyType.php deleted file mode 100644 index c64409d7be2e..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/DataPolicy_DataPolicyType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.DeleteDataPolicyRequest - */ -class DeleteDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/GetDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/GetDataPolicyRequest.php deleted file mode 100644 index ab1c978478f7..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/GetDataPolicyRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.GetDataPolicyRequest - */ -class GetDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesRequest.php deleted file mode 100644 index e6d7aa7fa4b0..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesRequest.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.ListDataPoliciesRequest - */ -class ListDataPoliciesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the project for which to list data policies. Format is - * `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the project for which to list data policies. Format is - * `projects/{project_number}/locations/{location_id}`. - * @type int $page_size - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * @type string $page_token - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the project for which to list data policies. Format is - * `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the project for which to list data policies. Format is - * `projects/{project_number}/locations/{location_id}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of data policies to return. Must be a value between 1 - * and 1000. - * If not set, defaults to 50. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The `nextPageToken` value returned from a previous list request, if any. If - * not set, defaults to an empty string. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesResponse.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesResponse.php deleted file mode 100644 index 9fbf4d5af4a3..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/ListDataPoliciesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.ListDataPoliciesResponse - */ -class ListDataPoliciesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policies = 1; - */ - private $data_policies; - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy>|\Google\Protobuf\Internal\RepeatedField $data_policies - * Data policies that belong to the requested project. - * @type string $next_page_token - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policies = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDataPolicies() - { - return $this->data_policies; - } - - /** - * Data policies that belong to the requested project. - * - * Generated from protobuf field repeated .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policies = 1; - * @param array<\Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDataPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy::class); - $this->data_policies = $arr; - - return $this; - } - - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token used to retrieve the next page of results, or empty if there are no - * more results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/UpdateDataPolicyRequest.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/UpdateDataPolicyRequest.php deleted file mode 100644 index d0cc036a020a..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/proto/src/Google/Cloud/BigQuery/DataPolicies/V1beta1/UpdateDataPolicyRequest.php +++ /dev/null @@ -1,145 +0,0 @@ -google.cloud.bigquery.datapolicies.v1beta1.UpdateDataPolicyRequest - */ -class UpdateDataPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_policy = null; - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy $data_policy - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * @type \Google\Protobuf\FieldMask $update_mask - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Datapolicies\V1Beta1\Datapolicy::initOnce(); - parent::__construct($data); - } - - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy|null - */ - public function getDataPolicy() - { - return $this->data_policy; - } - - public function hasDataPolicy() - { - return isset($this->data_policy); - } - - public function clearDataPolicy() - { - unset($this->data_policy); - } - - /** - * Required. Update the data policy's metadata. - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * - * Generated from protobuf field .google.cloud.bigquery.datapolicies.v1beta1.DataPolicy data_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy $var - * @return $this - */ - public function setDataPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy::class); - $this->data_policy = $var; - - return $this; - } - - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/create_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/create_data_policy.php deleted file mode 100644 index 7f1ece69af2c..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/create_data_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -createDataPolicy($formattedParent, $dataPolicy); - 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 = DataPolicyServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - create_data_policy_sample($formattedParent); -} -// [END bigquerydatapolicy_v1beta1_generated_DataPolicyService_CreateDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/delete_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/delete_data_policy.php deleted file mode 100644 index 160cc637bac0..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/delete_data_policy.php +++ /dev/null @@ -1,69 +0,0 @@ -deleteDataPolicy($formattedName); - 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 = DataPolicyServiceClient::dataPolicyName( - '[PROJECT]', - '[LOCATION]', - '[DATA_POLICY]' - ); - - delete_data_policy_sample($formattedName); -} -// [END bigquerydatapolicy_v1beta1_generated_DataPolicyService_DeleteDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_data_policy.php deleted file mode 100644 index 69da2915510e..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_data_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -getDataPolicy($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 = DataPolicyServiceClient::dataPolicyName( - '[PROJECT]', - '[LOCATION]', - '[DATA_POLICY]' - ); - - get_data_policy_sample($formattedName); -} -// [END bigquerydatapolicy_v1beta1_generated_DataPolicyService_GetDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_iam_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_iam_policy.php deleted file mode 100644 index 5eddcdd0f3fa..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/get_iam_policy.php +++ /dev/null @@ -1,66 +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 bigquerydatapolicy_v1beta1_generated_DataPolicyService_GetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/list_data_policies.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/list_data_policies.php deleted file mode 100644 index 1e154b8cd7dd..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/list_data_policies.php +++ /dev/null @@ -1,72 +0,0 @@ -listDataPolicies($formattedParent); - - /** @var DataPolicy $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 = DataPolicyServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_data_policies_sample($formattedParent); -} -// [END bigquerydatapolicy_v1beta1_generated_DataPolicyService_ListDataPolicies_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/set_iam_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/set_iam_policy.php deleted file mode 100644 index aa2a1dc8d51e..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/set_iam_policy.php +++ /dev/null @@ -1,69 +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 bigquerydatapolicy_v1beta1_generated_DataPolicyService_SetIamPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/test_iam_permissions.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/test_iam_permissions.php deleted file mode 100644 index 27f8e15c6fc2..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,74 +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 bigquerydatapolicy_v1beta1_generated_DataPolicyService_TestIamPermissions_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/update_data_policy.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/update_data_policy.php deleted file mode 100644 index cd503c313c7f..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/samples/V1beta1/DataPolicyServiceClient/update_data_policy.php +++ /dev/null @@ -1,57 +0,0 @@ -updateDataPolicy($dataPolicy); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END bigquerydatapolicy_v1beta1_generated_DataPolicyService_UpdateDataPolicy_sync] diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/DataPolicyServiceClient.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/DataPolicyServiceClient.php deleted file mode 100644 index 131bf35fc054..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/DataPolicyServiceClient.php +++ /dev/null @@ -1,36 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->createDataPolicy($formattedParent, $dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * 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. - * - * @experimental - */ -class DataPolicyServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'bigquerydatapolicy.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/bigquery', - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $dataPolicyNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/data_policy_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/data_policy_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/data_policy_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/data_policy_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getDataPolicyNameTemplate() - { - if (self::$dataPolicyNameTemplate == null) { - self::$dataPolicyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dataPolicies/{data_policy}'); - } - - return self::$dataPolicyNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'dataPolicy' => self::getDataPolicyNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a data_policy - * resource. - * - * @param string $project - * @param string $location - * @param string $dataPolicy - * - * @return string The formatted data_policy resource. - * - * @experimental - */ - public static function dataPolicyName($project, $location, $dataPolicy) - { - return self::getDataPolicyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'data_policy' => $dataPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - * - * @experimental - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - dataPolicy: projects/{project}/locations/{location}/dataPolicies/{data_policy} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'bigquerydatapolicy.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a new data policy under a project with the given `dataPolicyId` - * (used as the display name), policy tag, and data policy type. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedParent = $dataPolicyServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->createDataPolicy($formattedParent, $dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the project that the data policy will belong to. The - * format is `projects/{project_number}/locations/{location_id}`. - * @param DataPolicy $dataPolicy Required. The data policy to create. The `name` field does not need to be - * provided for the data policy creation. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createDataPolicy($parent, $dataPolicy, array $optionalArgs = []) - { - $request = new CreateDataPolicyRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDataPolicy($dataPolicy); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the data policy specified by its resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedName = $dataPolicyServiceClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - * $dataPolicyServiceClient->deleteDataPolicy($formattedName); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the data policy to delete. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function deleteDataPolicy($name, array $optionalArgs = []) - { - $request = new DeleteDataPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteDataPolicy', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the data policy specified by its resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedName = $dataPolicyServiceClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - * $response = $dataPolicyServiceClient->getDataPolicy($formattedName); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $name Required. Resource name of the requested data policy. Format is - * `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getDataPolicy($name, array $optionalArgs = []) - { - $request = new GetDataPolicyRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the IAM policy for the specified data policy. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $response = $dataPolicyServiceClient->getIamPolicy($resource); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * List all of the data policies in the specified parent project. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $formattedParent = $dataPolicyServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dataPolicyServiceClient->listDataPolicies($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dataPolicyServiceClient->listDataPolicies($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the project for which to list data policies. Format is - * `projects/{project_number}/locations/{location_id}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listDataPolicies($parent, array $optionalArgs = []) - { - $request = new ListDataPoliciesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDataPolicies', $optionalArgs, ListDataPoliciesResponse::class, $request); - } - - /** - * Sets the IAM policy for the specified data policy. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $dataPolicyServiceClient->setIamPolicy($resource, $policy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the caller's permission on the specified data policy resource. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $dataPolicyServiceClient->testIamPermissions($resource, $permissions); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the metadata for an existing data policy. The target data policy - * can be specified by the resource name. - * - * Sample code: - * ``` - * $dataPolicyServiceClient = new DataPolicyServiceClient(); - * try { - * $dataPolicy = new DataPolicy(); - * $response = $dataPolicyServiceClient->updateDataPolicy($dataPolicy); - * } finally { - * $dataPolicyServiceClient->close(); - * } - * ``` - * - * @param DataPolicy $dataPolicy Required. Update the data policy's metadata. - * - * The target data policy is determined by the `name` field. - * Other fields are updated to the specified values based on the field masks. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The update mask applies to the resource. For the `FieldMask` definition, - * see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - * If not set, defaults to all of the fields that are allowed to update. - * - * Updates to the `name` and `dataPolicyId` fields are not allowed. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\DataPolicies\V1beta1\DataPolicy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateDataPolicy($dataPolicy, array $optionalArgs = []) - { - $request = new UpdateDataPolicyRequest(); - $requestParamHeaders = []; - $request->setDataPolicy($dataPolicy); - $requestParamHeaders['data_policy.name'] = $dataPolicy->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateDataPolicy', DataPolicy::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/gapic_metadata.json b/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/gapic_metadata.json deleted file mode 100644 index 298e8702b71f..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/gapic_metadata.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.bigquery.datapolicies.v1beta1", - "libraryPackage": "Google\\Cloud\\BigQuery\\DataPolicies\\V1beta1", - "services": { - "DataPolicyService": { - "clients": { - "grpc": { - "libraryClient": "DataPolicyServiceGapicClient", - "rpcs": { - "CreateDataPolicy": { - "methods": [ - "createDataPolicy" - ] - }, - "DeleteDataPolicy": { - "methods": [ - "deleteDataPolicy" - ] - }, - "GetDataPolicy": { - "methods": [ - "getDataPolicy" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "ListDataPolicies": { - "methods": [ - "listDataPolicies" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - }, - "UpdateDataPolicy": { - "methods": [ - "updateDataPolicy" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_client_config.json b/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_client_config.json deleted file mode 100644 index 1970c986fa2b..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_client_config.json +++ /dev/null @@ -1,74 +0,0 @@ -{ - "interfaces": { - "google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDataPolicies": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDataPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_descriptor_config.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_descriptor_config.php deleted file mode 100644 index a2034625444d..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_descriptor_config.php +++ /dev/null @@ -1,18 +0,0 @@ - [ - 'google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService' => [ - 'ListDataPolicies' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataPolicies', - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_rest_client_config.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_rest_client_config.php deleted file mode 100644 index 3806a270227a..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/src/V1beta1/resources/data_policy_service_rest_client_config.php +++ /dev/null @@ -1,102 +0,0 @@ - [ - 'google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService' => [ - 'CreateDataPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*}/dataPolicies', - 'body' => 'data_policy', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataPolicy' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDataPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*/dataPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataPolicies/*}:getIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'ListDataPolicies' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta1/{parent=projects/*/locations/*}/dataPolicies', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataPolicies/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta1/{resource=projects/*/locations/*/dataPolicies/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateDataPolicy' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1beta1/{data_policy.name=projects/*/locations/*/dataPolicies/*}', - 'body' => 'data_policy', - 'placeholders' => [ - 'data_policy.name' => [ - 'getters' => [ - 'getDataPolicy', - 'getName', - ], - ], - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryDataPolicies/v1beta1/tests/Unit/V1beta1/DataPolicyServiceClientTest.php b/owl-bot-staging/BigQueryDataPolicies/v1beta1/tests/Unit/V1beta1/DataPolicyServiceClientTest.php deleted file mode 100644 index c37f3b0647e0..000000000000 --- a/owl-bot-staging/BigQueryDataPolicies/v1beta1/tests/Unit/V1beta1/DataPolicyServiceClientTest.php +++ /dev/null @@ -1,576 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DataPolicyServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DataPolicyServiceClient($options); - } - - /** @test */ - public function createDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name = 'name3373707'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataPolicy = new DataPolicy(); - $response = $gapicClient->createDataPolicy($formattedParent, $dataPolicy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/CreateDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDataPolicy(); - $this->assertProtobufEquals($dataPolicy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dataPolicy = new DataPolicy(); - try { - $gapicClient->createDataPolicy($formattedParent, $dataPolicy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - $gapicClient->deleteDataPolicy($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/DeleteDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - try { - $gapicClient->deleteDataPolicy($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name2 = 'name2-1052831874'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name2); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - $response = $gapicClient->getDataPolicy($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/GetDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dataPolicyName('[PROJECT]', '[LOCATION]', '[DATA_POLICY]'); - try { - $gapicClient->getDataPolicy($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataPoliciesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataPoliciesElement = new DataPolicy(); - $dataPolicies = [ - $dataPoliciesElement, - ]; - $expectedResponse = new ListDataPoliciesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataPolicies($dataPolicies); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDataPolicies($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataPolicies()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/ListDataPolicies', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDataPoliciesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDataPolicies($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $policyTag = 'policyTag1593879309'; - $name = 'name3373707'; - $dataPolicyId = 'dataPolicyId456934643'; - $expectedResponse = new DataPolicy(); - $expectedResponse->setPolicyTag($policyTag); - $expectedResponse->setName($name); - $expectedResponse->setDataPolicyId($dataPolicyId); - $transport->addResponse($expectedResponse); - // Mock request - $dataPolicy = new DataPolicy(); - $response = $gapicClient->updateDataPolicy($dataPolicy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.datapolicies.v1beta1.DataPolicyService/UpdateDataPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getDataPolicy(); - $this->assertProtobufEquals($dataPolicy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $dataPolicy = new DataPolicy(); - try { - $gapicClient->updateDataPolicy($dataPolicy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationEntities.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationEntities.php deleted file mode 100644 index 053eb31309e1074702bcd80a5f573b4c8f48da03..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3589 zcmb_f-EQMV6y7vROQt`xX159zf+4Kft^~F=Ac4}BZGPNt#5Tz`X%Wa$`?8160=_+ zXZi)TS*bKR)db{CrpF{oa$>6+QZ~t-%9zb+kZfwY$v2b;8Ysl5@jsz|uhbSQ8=iktXcIAFQX4wH0>~_ox&XNb{kN42dTU4r4 z2#w{S%w$bs%qg++HZIdB&sM;SeB`?2-d= z)gk#b;I9>T{u^MMLsVejX-PrL1|#sd%cGOe0PJ#cOTdcI$#FGEU!rx;Z?Ee+p!kth zcAnK%7on+BETi-}xeOyH?W634Zu$gb#C<;!zHcDxBt{&xwD5JR@C;>xQ%U#GM!Qq) zsNIuByQNm^2X(c!en-loZ0)#w&{7DfzF;3>8JiObRBD93&sAPTqp@PzMxaM9Cx&C?dBiE0 z6vJ`hmke5sG5PtV9@?5Exu~-IS`fC~Bw?G;#YoGa+>s=-K>JrXy@E2{r4uG5Cw(iZ z$2qcA{3?mV*UlkN(GFMyp)rW-Qft@^iZ36s=$^oZs+0pYty=^8TC(yQyFFQ#=2;ck z94-NYT56-l36zpH&}#Fz`b2Gaj?0~pQ&R*>PZ2D`3D!QTR#mkI1k3VI2j%)x7%x`V z(257S7FjL)lSS)s^xA%pe|&@Vyo;6sQ^+4Lp`0Z0#x)`*HALQceAkL45#L1h6?vYQ zx-b(rrB2h(rnp+de2b&zR|0KJ#3%8tnYv{|W_*C|UO_i(-}3USaOUh)k()y0eoMV7|C&ONl53q{Wb?(LEtKzaeasu zqQ&3zt<(>-klW(21(6=w*L66c;nPiy)7u$|R>kT4zEC&}+8MdZ+Zh?!nPinternalAddGeneratedFile( - ' -ß -@google/cloud/bigquery/migration/v2/migration_error_details.proto"google.cloud.bigquery.migration.v2google/rpc/error_details.proto"² -ResourceErrorDetail4 - resource_info ( 2.google.rpc.ResourceInfoBàAK - error_details ( 2/.google.cloud.bigquery.migration.v2.ErrorDetailBàA - error_count (BàA"‡ - ErrorDetailH -location ( 21.google.cloud.bigquery.migration.v2.ErrorLocationBàA. - -error_info ( 2.google.rpc.ErrorInfoBàA"7 - ErrorLocation -line (BàA -column (BàABÖ -&com.google.cloud.bigquery.migration.v2BMigrationErrorDetailsProtoPZDcloud.google.com/go/bigquery/migration/apiv2/migrationpb;migrationpbª"Google.Cloud.BigQuery.Migration.V2Ê"Google\\Cloud\\BigQuery\\Migration\\V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationMetrics.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/MigrationMetrics.php deleted file mode 100644 index 21788890345126b0a90954c3308ebc80bdc8cdbb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1890 zcmbVN&2G~`5XMbg(oMy|P>6bA300d);DC#Ia7nAUp=pImgNS-SmLmUb(iM(v>~*Aq z`T{&kZ@dOK-hd15!R)T>1o}fEr+9Y0Z)d)loq4$vokZv{?vQ}QHX|N(PBA+nIEq6S zx}lGqbTA+>cEeFbeG+RJw~z3fqaJ?MKIlCHXcDHeOAI^=!=XM*7DBQiq6)?`trk!-;QWwzy<3&nPRfVmmf?y$mY)ua-?_(&_WHC=Pn&;KNWJCC<+fPZKokpZO0|$5XRV|AfV$x(KCQYdwbN3#2 zOM(`vNY?%b8hF)`V6fJ%rI4Jj!Jl&|>Nc8>La0enoyDbkMPJX+*9fO|IYPux`=X#Z z@u`}qENTlmi7YGnvzu^nl@54M08VY9IU$KqqoQj!A^<%+p-gRz7JsALKnNN#W_@0s zEU4w2Gq0V-A);@kBF|Bo1fGQOqEz(1KxS&^yxK(=>OF)Um==AR3a@y1|CYLhDxlBi zi_FZaOJKf_7QGNA9?9&yii))J#~%zc`z+WOz`lu8Z)z-Lr*m*x(W`lGynCjH$Nnwz zb|$U)T|uj`7;@KZ>TE9kIibZ{?<()x5|zKPaMT!vm#q(oV|s%`&Q|dNBj z+vUqbgJtoSuOF?rRXf(dinternalAddGeneratedFile( - ' -Ô -:google/cloud/bigquery/migration/v2/migration_service.proto"google.cloud.bigquery.migration.v2google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.proto;google/cloud/bigquery/migration/v2/migration_entities.protogoogle/protobuf/empty.proto google/protobuf/field_mask.proto"³ -CreateMigrationWorkflowRequest9 -parent ( B)àAúA# -!locations.googleapis.com/LocationV -migration_workflow ( 25.google.cloud.bigquery.migration.v2.MigrationWorkflowBàA"– -GetMigrationWorkflowRequestH -name ( B:àAúA4 -2bigquerymigration.googleapis.com/MigrationWorkflow- - read_mask ( 2.google.protobuf.FieldMask"° -ListMigrationWorkflowsRequest9 -parent ( B)àAúA# -!locations.googleapis.com/Location- - read_mask ( 2.google.protobuf.FieldMask - page_size ( - -page_token ( " -ListMigrationWorkflowsResponseR -migration_workflows ( 25.google.cloud.bigquery.migration.v2.MigrationWorkflow -next_page_token ( "j -DeleteMigrationWorkflowRequestH -name ( B:àAúA4 -2bigquerymigration.googleapis.com/MigrationWorkflow"i -StartMigrationWorkflowRequestH -name ( B:àAúA4 -2bigquerymigration.googleapis.com/MigrationWorkflow"™ -GetMigrationSubtaskRequestG -name ( B9àAúA3 -1bigquerymigration.googleapis.com/MigrationSubtask2 - read_mask ( 2.google.protobuf.FieldMaskBàA"ä -ListMigrationSubtasksRequestJ -parent ( B:àAúA4 -2bigquerymigration.googleapis.com/MigrationWorkflow2 - read_mask ( 2.google.protobuf.FieldMaskBàA - page_size (BàA - -page_token ( BàA -filter ( BàA"Š -ListMigrationSubtasksResponseP -migration_subtasks ( 24.google.cloud.bigquery.migration.v2.MigrationSubtask -next_page_token ( 2Ë -MigrationServiceû -CreateMigrationWorkflowB.google.cloud.bigquery.migration.v2.CreateMigrationWorkflowRequest5.google.cloud.bigquery.migration.v2.MigrationWorkflow"e‚Óä“C"-/v2/{parent=projects/*/locations/*}/workflows:migration_workflowÚAparent,migration_workflowÌ -GetMigrationWorkflow?.google.cloud.bigquery.migration.v2.GetMigrationWorkflowRequest5.google.cloud.bigquery.migration.v2.MigrationWorkflow"<‚Óä“/-/v2/{name=projects/*/locations/*/workflows/*}ÚAnameß -ListMigrationWorkflowsA.google.cloud.bigquery.migration.v2.ListMigrationWorkflowsRequestB.google.cloud.bigquery.migration.v2.ListMigrationWorkflowsResponse">‚Óä“/-/v2/{parent=projects/*/locations/*}/workflowsÚAparent³ -DeleteMigrationWorkflowB.google.cloud.bigquery.migration.v2.DeleteMigrationWorkflowRequest.google.protobuf.Empty"<‚Óä“/*-/v2/{name=projects/*/locations/*/workflows/*}ÚAnameº -StartMigrationWorkflowA.google.cloud.bigquery.migration.v2.StartMigrationWorkflowRequest.google.protobuf.Empty"E‚Óä“8"3/v2/{name=projects/*/locations/*/workflows/*}:start:*ÚAnameÔ -GetMigrationSubtask>.google.cloud.bigquery.migration.v2.GetMigrationSubtaskRequest4.google.cloud.bigquery.migration.v2.MigrationSubtask"G‚Óä“:8/v2/{name=projects/*/locations/*/workflows/*/subtasks/*}ÚAnameç -ListMigrationSubtasks@.google.cloud.bigquery.migration.v2.ListMigrationSubtasksRequestA.google.cloud.bigquery.migration.v2.ListMigrationSubtasksResponse"I‚Óä“:8/v2/{parent=projects/*/locations/*/workflows/*}/subtasksÚAparentTÊA bigquerymigration.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformBÑ -&com.google.cloud.bigquery.migration.v2BMigrationServiceProtoPZDcloud.google.com/go/bigquery/migration/apiv2/migrationpb;migrationpbª"Google.Cloud.BigQuery.Migration.V2Ê"Google\\Cloud\\BigQuery\\Migration\\V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/TranslationConfig.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/GPBMetadata/Google/Cloud/Bigquery/Migration/V2/TranslationConfig.php deleted file mode 100644 index 3944fb406424b0e3cabd32d22ea9c6b15b5521a1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3630 zcmbuC-E!Mh5XbApP2x@BC@L+6DUA4;dhB#uhSP#Vl7 zIw6wnSk%%iLmGIa5pg8Vn%cTS97U3LHTb`M%`!*&SmECRFx4q>ZB--EX}i)OR2`~R?VWOD z@0cNbl>pgmgvj1?=?FkGRM(ZdG5VO3;TMqb$Myz>u1PM%uWHgm-RBaETeTOpP2omV72#`_Q&-SLzb;7*p`K$Naor4X8~w$VJ^5A- zbd-m~=(8sn!GmZaGkXMozY9nIBXpwd8!J5SN*H$~in}r^$*1*Y` zB`K}JPeh|lL^OQDIRehs#AC<@N`{yuxTLVop&zG#R(%r&2{eb0?At@i0D%%>&I%hG z@Fb0j4nL4Jb0$83yhHFDx-{6{!WLq3m3`O?(1xY)zw(5zvopDquITje+Q{<*1rLBAlPXsoZUG%NU04VhMF# zx{2NM(W$}+zB@Nn+l^J`IP}Xj&@uybeEXP;LTALmJ0lhf>4jeVrZMgkL>3m8 zI7p3L-+qg|yg2W0?C6% z{|NWrc!`RquoYeyxTWiOxKm~03QYbz1N$pa#R_crmluy$+R71M^v}s$tipzW+ZFul zB~>{~Gz-@}1^-;bI4pu|kfn1wOr=!yXOWv;gmh&(pyD!?y8My;n)pEC7DR*j^mH-=_%jflSN4P8AgS}`;@Nk1sPOh5A zoU$pu03qQj-@yexdDEBhlXrRxezLoJ$xrUOT!viS^b|lCl9B2ec#*u*ldz*)$Cl`?419z$PKvW%d9c#T^5(yt`Jw7J!D0JpO^ajeO{0)%>o^TXEwVj0 zO8ouDntaOV9)-_6N?7HTXzo$2ORvL4ygoogle.cloud.bigquery.migration.v2.AzureSynapseDialect - */ -class AzureSynapseDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/BigQueryDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/BigQueryDialect.php deleted file mode 100644 index 633c28794cb2..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/BigQueryDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.BigQueryDialect - */ -class BigQueryDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/CreateMigrationWorkflowRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/CreateMigrationWorkflowRequest.php deleted file mode 100644 index cf86b9f22bb6..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/CreateMigrationWorkflowRequest.php +++ /dev/null @@ -1,132 +0,0 @@ -google.cloud.bigquery.migration.v2.CreateMigrationWorkflowRequest - */ -class CreateMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The migration workflow to create. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflow = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $migration_workflow = null; - - /** - * @param string $parent Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * Please see {@see MigrationServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $migrationWorkflow Required. The migration workflow to create. - * - * @return \Google\Cloud\BigQuery\Migration\V2\CreateMigrationWorkflowRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $migrationWorkflow): self - { - return (new self()) - ->setParent($parent) - ->setMigrationWorkflow($migrationWorkflow); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * @type \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $migration_workflow - * Required. The migration workflow to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The migration workflow to create. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflow = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow|null - */ - public function getMigrationWorkflow() - { - return $this->migration_workflow; - } - - public function hasMigrationWorkflow() - { - return isset($this->migration_workflow); - } - - public function clearMigrationWorkflow() - { - unset($this->migration_workflow); - } - - /** - * Required. The migration workflow to create. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflow = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow $var - * @return $this - */ - public function setMigrationWorkflow($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow::class); - $this->migration_workflow = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/DeleteMigrationWorkflowRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/DeleteMigrationWorkflowRequest.php deleted file mode 100644 index 8d1a839efb89..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/DeleteMigrationWorkflowRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.migration.v2.DeleteMigrationWorkflowRequest - */ -class DeleteMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\DeleteMigrationWorkflowRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Dialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Dialect.php deleted file mode 100644 index 72cba8fabd08..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Dialect.php +++ /dev/null @@ -1,504 +0,0 @@ -google.cloud.bigquery.migration.v2.Dialect - */ -class Dialect extends \Google\Protobuf\Internal\Message -{ - protected $dialect_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\Migration\V2\BigQueryDialect $bigquery_dialect - * The BigQuery dialect - * @type \Google\Cloud\BigQuery\Migration\V2\HiveQLDialect $hiveql_dialect - * The HiveQL dialect - * @type \Google\Cloud\BigQuery\Migration\V2\RedshiftDialect $redshift_dialect - * The Redshift dialect - * @type \Google\Cloud\BigQuery\Migration\V2\TeradataDialect $teradata_dialect - * The Teradata dialect - * @type \Google\Cloud\BigQuery\Migration\V2\OracleDialect $oracle_dialect - * The Oracle dialect - * @type \Google\Cloud\BigQuery\Migration\V2\SparkSQLDialect $sparksql_dialect - * The SparkSQL dialect - * @type \Google\Cloud\BigQuery\Migration\V2\SnowflakeDialect $snowflake_dialect - * The Snowflake dialect - * @type \Google\Cloud\BigQuery\Migration\V2\NetezzaDialect $netezza_dialect - * The Netezza dialect - * @type \Google\Cloud\BigQuery\Migration\V2\AzureSynapseDialect $azure_synapse_dialect - * The Azure Synapse dialect - * @type \Google\Cloud\BigQuery\Migration\V2\VerticaDialect $vertica_dialect - * The Vertica dialect - * @type \Google\Cloud\BigQuery\Migration\V2\SQLServerDialect $sql_server_dialect - * The SQL Server dialect - * @type \Google\Cloud\BigQuery\Migration\V2\PostgresqlDialect $postgresql_dialect - * The Postgresql dialect - * @type \Google\Cloud\BigQuery\Migration\V2\PrestoDialect $presto_dialect - * The Presto dialect - * @type \Google\Cloud\BigQuery\Migration\V2\MySQLDialect $mysql_dialect - * The MySQL dialect - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The BigQuery dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.BigQueryDialect bigquery_dialect = 1; - * @return \Google\Cloud\BigQuery\Migration\V2\BigQueryDialect|null - */ - public function getBigqueryDialect() - { - return $this->readOneof(1); - } - - public function hasBigqueryDialect() - { - return $this->hasOneof(1); - } - - /** - * The BigQuery dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.BigQueryDialect bigquery_dialect = 1; - * @param \Google\Cloud\BigQuery\Migration\V2\BigQueryDialect $var - * @return $this - */ - public function setBigqueryDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\BigQueryDialect::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The HiveQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.HiveQLDialect hiveql_dialect = 2; - * @return \Google\Cloud\BigQuery\Migration\V2\HiveQLDialect|null - */ - public function getHiveqlDialect() - { - return $this->readOneof(2); - } - - public function hasHiveqlDialect() - { - return $this->hasOneof(2); - } - - /** - * The HiveQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.HiveQLDialect hiveql_dialect = 2; - * @param \Google\Cloud\BigQuery\Migration\V2\HiveQLDialect $var - * @return $this - */ - public function setHiveqlDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\HiveQLDialect::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The Redshift dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.RedshiftDialect redshift_dialect = 3; - * @return \Google\Cloud\BigQuery\Migration\V2\RedshiftDialect|null - */ - public function getRedshiftDialect() - { - return $this->readOneof(3); - } - - public function hasRedshiftDialect() - { - return $this->hasOneof(3); - } - - /** - * The Redshift dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.RedshiftDialect redshift_dialect = 3; - * @param \Google\Cloud\BigQuery\Migration\V2\RedshiftDialect $var - * @return $this - */ - public function setRedshiftDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\RedshiftDialect::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * The Teradata dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TeradataDialect teradata_dialect = 4; - * @return \Google\Cloud\BigQuery\Migration\V2\TeradataDialect|null - */ - public function getTeradataDialect() - { - return $this->readOneof(4); - } - - public function hasTeradataDialect() - { - return $this->hasOneof(4); - } - - /** - * The Teradata dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TeradataDialect teradata_dialect = 4; - * @param \Google\Cloud\BigQuery\Migration\V2\TeradataDialect $var - * @return $this - */ - public function setTeradataDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\TeradataDialect::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * The Oracle dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.OracleDialect oracle_dialect = 5; - * @return \Google\Cloud\BigQuery\Migration\V2\OracleDialect|null - */ - public function getOracleDialect() - { - return $this->readOneof(5); - } - - public function hasOracleDialect() - { - return $this->hasOneof(5); - } - - /** - * The Oracle dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.OracleDialect oracle_dialect = 5; - * @param \Google\Cloud\BigQuery\Migration\V2\OracleDialect $var - * @return $this - */ - public function setOracleDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\OracleDialect::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * The SparkSQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SparkSQLDialect sparksql_dialect = 6; - * @return \Google\Cloud\BigQuery\Migration\V2\SparkSQLDialect|null - */ - public function getSparksqlDialect() - { - return $this->readOneof(6); - } - - public function hasSparksqlDialect() - { - return $this->hasOneof(6); - } - - /** - * The SparkSQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SparkSQLDialect sparksql_dialect = 6; - * @param \Google\Cloud\BigQuery\Migration\V2\SparkSQLDialect $var - * @return $this - */ - public function setSparksqlDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\SparkSQLDialect::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * The Snowflake dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SnowflakeDialect snowflake_dialect = 7; - * @return \Google\Cloud\BigQuery\Migration\V2\SnowflakeDialect|null - */ - public function getSnowflakeDialect() - { - return $this->readOneof(7); - } - - public function hasSnowflakeDialect() - { - return $this->hasOneof(7); - } - - /** - * The Snowflake dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SnowflakeDialect snowflake_dialect = 7; - * @param \Google\Cloud\BigQuery\Migration\V2\SnowflakeDialect $var - * @return $this - */ - public function setSnowflakeDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\SnowflakeDialect::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * The Netezza dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NetezzaDialect netezza_dialect = 8; - * @return \Google\Cloud\BigQuery\Migration\V2\NetezzaDialect|null - */ - public function getNetezzaDialect() - { - return $this->readOneof(8); - } - - public function hasNetezzaDialect() - { - return $this->hasOneof(8); - } - - /** - * The Netezza dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NetezzaDialect netezza_dialect = 8; - * @param \Google\Cloud\BigQuery\Migration\V2\NetezzaDialect $var - * @return $this - */ - public function setNetezzaDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\NetezzaDialect::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * The Azure Synapse dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.AzureSynapseDialect azure_synapse_dialect = 9; - * @return \Google\Cloud\BigQuery\Migration\V2\AzureSynapseDialect|null - */ - public function getAzureSynapseDialect() - { - return $this->readOneof(9); - } - - public function hasAzureSynapseDialect() - { - return $this->hasOneof(9); - } - - /** - * The Azure Synapse dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.AzureSynapseDialect azure_synapse_dialect = 9; - * @param \Google\Cloud\BigQuery\Migration\V2\AzureSynapseDialect $var - * @return $this - */ - public function setAzureSynapseDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\AzureSynapseDialect::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * The Vertica dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.VerticaDialect vertica_dialect = 10; - * @return \Google\Cloud\BigQuery\Migration\V2\VerticaDialect|null - */ - public function getVerticaDialect() - { - return $this->readOneof(10); - } - - public function hasVerticaDialect() - { - return $this->hasOneof(10); - } - - /** - * The Vertica dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.VerticaDialect vertica_dialect = 10; - * @param \Google\Cloud\BigQuery\Migration\V2\VerticaDialect $var - * @return $this - */ - public function setVerticaDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\VerticaDialect::class); - $this->writeOneof(10, $var); - - return $this; - } - - /** - * The SQL Server dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SQLServerDialect sql_server_dialect = 11; - * @return \Google\Cloud\BigQuery\Migration\V2\SQLServerDialect|null - */ - public function getSqlServerDialect() - { - return $this->readOneof(11); - } - - public function hasSqlServerDialect() - { - return $this->hasOneof(11); - } - - /** - * The SQL Server dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SQLServerDialect sql_server_dialect = 11; - * @param \Google\Cloud\BigQuery\Migration\V2\SQLServerDialect $var - * @return $this - */ - public function setSqlServerDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\SQLServerDialect::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * The Postgresql dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.PostgresqlDialect postgresql_dialect = 12; - * @return \Google\Cloud\BigQuery\Migration\V2\PostgresqlDialect|null - */ - public function getPostgresqlDialect() - { - return $this->readOneof(12); - } - - public function hasPostgresqlDialect() - { - return $this->hasOneof(12); - } - - /** - * The Postgresql dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.PostgresqlDialect postgresql_dialect = 12; - * @param \Google\Cloud\BigQuery\Migration\V2\PostgresqlDialect $var - * @return $this - */ - public function setPostgresqlDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\PostgresqlDialect::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * The Presto dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.PrestoDialect presto_dialect = 13; - * @return \Google\Cloud\BigQuery\Migration\V2\PrestoDialect|null - */ - public function getPrestoDialect() - { - return $this->readOneof(13); - } - - public function hasPrestoDialect() - { - return $this->hasOneof(13); - } - - /** - * The Presto dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.PrestoDialect presto_dialect = 13; - * @param \Google\Cloud\BigQuery\Migration\V2\PrestoDialect $var - * @return $this - */ - public function setPrestoDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\PrestoDialect::class); - $this->writeOneof(13, $var); - - return $this; - } - - /** - * The MySQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MySQLDialect mysql_dialect = 14; - * @return \Google\Cloud\BigQuery\Migration\V2\MySQLDialect|null - */ - public function getMysqlDialect() - { - return $this->readOneof(14); - } - - public function hasMysqlDialect() - { - return $this->hasOneof(14); - } - - /** - * The MySQL dialect - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MySQLDialect mysql_dialect = 14; - * @param \Google\Cloud\BigQuery\Migration\V2\MySQLDialect $var - * @return $this - */ - public function setMysqlDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\MySQLDialect::class); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * @return string - */ - public function getDialectValue() - { - return $this->whichOneof("dialect_value"); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorDetail.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorDetail.php deleted file mode 100644 index b12388d8d92f..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorDetail.php +++ /dev/null @@ -1,122 +0,0 @@ -google.cloud.bigquery.migration.v2.ErrorDetail - */ -class ErrorDetail extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The exact location within the resource (if applicable). - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.ErrorLocation location = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $location = null; - /** - * Required. Describes the cause of the error with structured detail. - * - * Generated from protobuf field .google.rpc.ErrorInfo error_info = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $error_info = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\Migration\V2\ErrorLocation $location - * Optional. The exact location within the resource (if applicable). - * @type \Google\Rpc\ErrorInfo $error_info - * Required. Describes the cause of the error with structured detail. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationErrorDetails::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The exact location within the resource (if applicable). - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.ErrorLocation location = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\BigQuery\Migration\V2\ErrorLocation|null - */ - public function getLocation() - { - return $this->location; - } - - public function hasLocation() - { - return isset($this->location); - } - - public function clearLocation() - { - unset($this->location); - } - - /** - * Optional. The exact location within the resource (if applicable). - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.ErrorLocation location = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\BigQuery\Migration\V2\ErrorLocation $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\ErrorLocation::class); - $this->location = $var; - - return $this; - } - - /** - * Required. Describes the cause of the error with structured detail. - * - * Generated from protobuf field .google.rpc.ErrorInfo error_info = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Rpc\ErrorInfo|null - */ - public function getErrorInfo() - { - return $this->error_info; - } - - public function hasErrorInfo() - { - return isset($this->error_info); - } - - public function clearErrorInfo() - { - unset($this->error_info); - } - - /** - * Required. Describes the cause of the error with structured detail. - * - * Generated from protobuf field .google.rpc.ErrorInfo error_info = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Rpc\ErrorInfo $var - * @return $this - */ - public function setErrorInfo($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\ErrorInfo::class); - $this->error_info = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorLocation.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorLocation.php deleted file mode 100644 index b2d7144c0b51..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ErrorLocation.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.bigquery.migration.v2.ErrorLocation - */ -class ErrorLocation extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. If applicable, denotes the line where the error occurred. A zero - * value means that there is no line information. - * - * Generated from protobuf field int32 line = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $line = 0; - /** - * Optional. If applicable, denotes the column where the error occurred. A - * zero value means that there is no columns information. - * - * Generated from protobuf field int32 column = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $column = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $line - * Optional. If applicable, denotes the line where the error occurred. A zero - * value means that there is no line information. - * @type int $column - * Optional. If applicable, denotes the column where the error occurred. A - * zero value means that there is no columns information. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationErrorDetails::initOnce(); - parent::__construct($data); - } - - /** - * Optional. If applicable, denotes the line where the error occurred. A zero - * value means that there is no line information. - * - * Generated from protobuf field int32 line = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getLine() - { - return $this->line; - } - - /** - * Optional. If applicable, denotes the line where the error occurred. A zero - * value means that there is no line information. - * - * Generated from protobuf field int32 line = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setLine($var) - { - GPBUtil::checkInt32($var); - $this->line = $var; - - return $this; - } - - /** - * Optional. If applicable, denotes the column where the error occurred. A - * zero value means that there is no columns information. - * - * Generated from protobuf field int32 column = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getColumn() - { - return $this->column; - } - - /** - * Optional. If applicable, denotes the column where the error occurred. A - * zero value means that there is no columns information. - * - * Generated from protobuf field int32 column = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setColumn($var) - { - GPBUtil::checkInt32($var); - $this->column = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationSubtaskRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationSubtaskRequest.php deleted file mode 100644 index ac8f15bd9e87..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationSubtaskRequest.php +++ /dev/null @@ -1,130 +0,0 @@ -google.cloud.bigquery.migration.v2.GetMigrationSubtaskRequest - */ -class GetMigrationSubtaskRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $read_mask = null; - - /** - * @param string $name Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * Please see {@see MigrationServiceClient::migrationSubtaskName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\GetMigrationSubtaskRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * @type \Google\Protobuf\FieldMask $read_mask - * Optional. The list of fields to be retrieved. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getReadMask() - { - return $this->read_mask; - } - - public function hasReadMask() - { - return isset($this->read_mask); - } - - public function clearReadMask() - { - unset($this->read_mask); - } - - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setReadMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->read_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationWorkflowRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationWorkflowRequest.php deleted file mode 100644 index cf20c5101842..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/GetMigrationWorkflowRequest.php +++ /dev/null @@ -1,130 +0,0 @@ -google.cloud.bigquery.migration.v2.GetMigrationWorkflowRequest - */ -class GetMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - */ - protected $read_mask = null; - - /** - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\GetMigrationWorkflowRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * @type \Google\Protobuf\FieldMask $read_mask - * The list of fields to be retrieved. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getReadMask() - { - return $this->read_mask; - } - - public function hasReadMask() - { - return isset($this->read_mask); - } - - public function clearReadMask() - { - unset($this->read_mask); - } - - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setReadMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->read_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/HiveQLDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/HiveQLDialect.php deleted file mode 100644 index 4eba620616c9..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/HiveQLDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.HiveQLDialect - */ -class HiveQLDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksRequest.php deleted file mode 100644 index 5cdf51450e54..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksRequest.php +++ /dev/null @@ -1,256 +0,0 @@ -google.cloud.bigquery.migration.v2.ListMigrationSubtasksRequest - */ -class ListMigrationSubtasksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $read_mask = null; - /** - * Optional. The maximum number of migration tasks to return. The service may - * return fewer than this number. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A page token, received from previous `ListMigrationSubtasks` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationSubtasks` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. The filter to apply. This can be used to get the subtasks of a - * specific tasks in a workflow, e.g. `migration_task = "ab012"` where - * `"ab012"` is the task ID (not the name in the named map). - * - * Generated from protobuf field string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * @type \Google\Protobuf\FieldMask $read_mask - * Optional. The list of fields to be retrieved. - * @type int $page_size - * Optional. The maximum number of migration tasks to return. The service may - * return fewer than this number. - * @type string $page_token - * Optional. A page token, received from previous `ListMigrationSubtasks` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationSubtasks` - * must match the call that provided the page token. - * @type string $filter - * Optional. The filter to apply. This can be used to get the subtasks of a - * specific tasks in a workflow, e.g. `migration_task = "ab012"` where - * `"ab012"` is the task ID (not the name in the named map). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getReadMask() - { - return $this->read_mask; - } - - public function hasReadMask() - { - return isset($this->read_mask); - } - - public function clearReadMask() - { - unset($this->read_mask); - } - - /** - * Optional. The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setReadMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->read_mask = $var; - - return $this; - } - - /** - * Optional. The maximum number of migration tasks to return. The service may - * return fewer than this number. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of migration tasks to return. The service may - * return fewer than this number. - * - * Generated from protobuf field int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A page token, received from previous `ListMigrationSubtasks` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationSubtasks` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A page token, received from previous `ListMigrationSubtasks` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationSubtasks` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Optional. The filter to apply. This can be used to get the subtasks of a - * specific tasks in a workflow, e.g. `migration_task = "ab012"` where - * `"ab012"` is the task ID (not the name in the named map). - * - * Generated from protobuf field string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. The filter to apply. This can be used to get the subtasks of a - * specific tasks in a workflow, e.g. `migration_task = "ab012"` where - * `"ab012"` is the task ID (not the name in the named map). - * - * Generated from protobuf field string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksResponse.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksResponse.php deleted file mode 100644 index 5ef10e1eda97..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationSubtasksResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.migration.v2.ListMigrationSubtasksResponse - */ -class ListMigrationSubtasksResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The migration subtasks for the specified task. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationSubtask migration_subtasks = 1; - */ - private $migration_subtasks; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\Migration\V2\MigrationSubtask>|\Google\Protobuf\Internal\RepeatedField $migration_subtasks - * The migration subtasks for the specified task. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * The migration subtasks for the specified task. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationSubtask migration_subtasks = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMigrationSubtasks() - { - return $this->migration_subtasks; - } - - /** - * The migration subtasks for the specified task. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationSubtask migration_subtasks = 1; - * @param array<\Google\Cloud\BigQuery\Migration\V2\MigrationSubtask>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMigrationSubtasks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\MigrationSubtask::class); - $this->migration_subtasks = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsRequest.php deleted file mode 100644 index e3637ad33ae3..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsRequest.php +++ /dev/null @@ -1,214 +0,0 @@ -google.cloud.bigquery.migration.v2.ListMigrationWorkflowsRequest - */ -class ListMigrationWorkflowsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - */ - protected $read_mask = null; - /** - * The maximum number of migration workflows to return. The service may return - * fewer than this number. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * A page token, received from previous `ListMigrationWorkflows` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationWorkflows` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * Please see {@see MigrationServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * @type \Google\Protobuf\FieldMask $read_mask - * The list of fields to be retrieved. - * @type int $page_size - * The maximum number of migration workflows to return. The service may return - * fewer than this number. - * @type string $page_token - * A page token, received from previous `ListMigrationWorkflows` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationWorkflows` - * must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getReadMask() - { - return $this->read_mask; - } - - public function hasReadMask() - { - return isset($this->read_mask); - } - - public function clearReadMask() - { - unset($this->read_mask); - } - - /** - * The list of fields to be retrieved. - * - * Generated from protobuf field .google.protobuf.FieldMask read_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setReadMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->read_mask = $var; - - return $this; - } - - /** - * The maximum number of migration workflows to return. The service may return - * fewer than this number. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of migration workflows to return. The service may return - * fewer than this number. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from previous `ListMigrationWorkflows` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationWorkflows` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from previous `ListMigrationWorkflows` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMigrationWorkflows` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsResponse.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsResponse.php deleted file mode 100644 index 41d31c2cfebd..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ListMigrationWorkflowsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.bigquery.migration.v2.ListMigrationWorkflowsResponse - */ -class ListMigrationWorkflowsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The migration workflows for the specified project / location. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflows = 1; - */ - private $migration_workflows; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow>|\Google\Protobuf\Internal\RepeatedField $migration_workflows - * The migration workflows for the specified project / location. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * The migration workflows for the specified project / location. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflows = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMigrationWorkflows() - { - return $this->migration_workflows; - } - - /** - * The migration workflows for the specified project / location. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.MigrationWorkflow migration_workflows = 1; - * @param array<\Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMigrationWorkflows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow::class); - $this->migration_workflows = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationServiceGrpcClient.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationServiceGrpcClient.php deleted file mode 100644 index e771b58b30b7..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationServiceGrpcClient.php +++ /dev/null @@ -1,143 +0,0 @@ -_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/CreateMigrationWorkflow', - $argument, - ['\Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', 'decode'], - $metadata, $options); - } - - /** - * Gets a previously created migration workflow. - * @param \Google\Cloud\BigQuery\Migration\V2\GetMigrationWorkflowRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetMigrationWorkflow(\Google\Cloud\BigQuery\Migration\V2\GetMigrationWorkflowRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/GetMigrationWorkflow', - $argument, - ['\Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', 'decode'], - $metadata, $options); - } - - /** - * Lists previously created migration workflow. - * @param \Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListMigrationWorkflows(\Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/ListMigrationWorkflows', - $argument, - ['\Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes a migration workflow by name. - * @param \Google\Cloud\BigQuery\Migration\V2\DeleteMigrationWorkflowRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteMigrationWorkflow(\Google\Cloud\BigQuery\Migration\V2\DeleteMigrationWorkflowRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/DeleteMigrationWorkflow', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Starts a previously created migration workflow. I.e., the state transitions - * from DRAFT to RUNNING. This is a no-op if the state is already RUNNING. - * An error will be signaled if the state is anything other than DRAFT or - * RUNNING. - * @param \Google\Cloud\BigQuery\Migration\V2\StartMigrationWorkflowRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function StartMigrationWorkflow(\Google\Cloud\BigQuery\Migration\V2\StartMigrationWorkflowRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/StartMigrationWorkflow', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Gets a previously created migration subtask. - * @param \Google\Cloud\BigQuery\Migration\V2\GetMigrationSubtaskRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetMigrationSubtask(\Google\Cloud\BigQuery\Migration\V2\GetMigrationSubtaskRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/GetMigrationSubtask', - $argument, - ['\Google\Cloud\BigQuery\Migration\V2\MigrationSubtask', 'decode'], - $metadata, $options); - } - - /** - * Lists previously created migration subtasks. - * @param \Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListMigrationSubtasks(\Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.bigquery.migration.v2.MigrationService/ListMigrationSubtasks', - $argument, - ['\Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask.php deleted file mode 100644 index 89a6b5afbe96..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask.php +++ /dev/null @@ -1,449 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationSubtask - */ -class MigrationSubtask extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Immutable. The resource name for the migration subtask. The ID - * is server-generated. - * Example: `projects/123/locations/us/workflows/345/subtasks/678` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * The unique ID of the task to which this subtask belongs. - * - * Generated from protobuf field string task_id = 2; - */ - protected $task_id = ''; - /** - * The type of the Subtask. The migration service does not check whether this - * is a known type. It is up to the task creator (i.e. orchestrator or worker) - * to ensure it only creates subtasks for which there are compatible workers - * polling for Subtasks. - * - * Generated from protobuf field string type = 3; - */ - protected $type = ''; - /** - * Output only. The current state of the subtask. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationSubtask.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $processing_error = null; - /** - * Output only. Provides details to errors and issues encountered while - * processing the subtask. Presence of error details does not mean that the - * subtask failed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ResourceErrorDetail resource_error_details = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $resource_error_details; - /** - * The number or resources with errors. Note: This is not the total - * number of errors as each resource can have more than one error. - * This is used to indicate truncation by having a `resource_error_count` - * that is higher than the size of `resource_error_details`. - * - * Generated from protobuf field int32 resource_error_count = 13; - */ - protected $resource_error_count = 0; - /** - * Time when the subtask was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - */ - protected $create_time = null; - /** - * Time when the subtask was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 8; - */ - protected $last_update_time = null; - /** - * The metrics for the subtask. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.TimeSeries metrics = 11; - */ - private $metrics; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Immutable. The resource name for the migration subtask. The ID - * is server-generated. - * Example: `projects/123/locations/us/workflows/345/subtasks/678` - * @type string $task_id - * The unique ID of the task to which this subtask belongs. - * @type string $type - * The type of the Subtask. The migration service does not check whether this - * is a known type. It is up to the task creator (i.e. orchestrator or worker) - * to ensure it only creates subtasks for which there are compatible workers - * polling for Subtasks. - * @type int $state - * Output only. The current state of the subtask. - * @type \Google\Rpc\ErrorInfo $processing_error - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * @type array<\Google\Cloud\BigQuery\Migration\V2\ResourceErrorDetail>|\Google\Protobuf\Internal\RepeatedField $resource_error_details - * Output only. Provides details to errors and issues encountered while - * processing the subtask. Presence of error details does not mean that the - * subtask failed. - * @type int $resource_error_count - * The number or resources with errors. Note: This is not the total - * number of errors as each resource can have more than one error. - * This is used to indicate truncation by having a `resource_error_count` - * that is higher than the size of `resource_error_details`. - * @type \Google\Protobuf\Timestamp $create_time - * Time when the subtask was created. - * @type \Google\Protobuf\Timestamp $last_update_time - * Time when the subtask was last updated. - * @type array<\Google\Cloud\BigQuery\Migration\V2\TimeSeries>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metrics for the subtask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationEntities::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Immutable. The resource name for the migration subtask. The ID - * is server-generated. - * Example: `projects/123/locations/us/workflows/345/subtasks/678` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Immutable. The resource name for the migration subtask. The ID - * is server-generated. - * Example: `projects/123/locations/us/workflows/345/subtasks/678` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The unique ID of the task to which this subtask belongs. - * - * Generated from protobuf field string task_id = 2; - * @return string - */ - public function getTaskId() - { - return $this->task_id; - } - - /** - * The unique ID of the task to which this subtask belongs. - * - * Generated from protobuf field string task_id = 2; - * @param string $var - * @return $this - */ - public function setTaskId($var) - { - GPBUtil::checkString($var, True); - $this->task_id = $var; - - return $this; - } - - /** - * The type of the Subtask. The migration service does not check whether this - * is a known type. It is up to the task creator (i.e. orchestrator or worker) - * to ensure it only creates subtasks for which there are compatible workers - * polling for Subtasks. - * - * Generated from protobuf field string type = 3; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The type of the Subtask. The migration service does not check whether this - * is a known type. It is up to the task creator (i.e. orchestrator or worker) - * to ensure it only creates subtasks for which there are compatible workers - * polling for Subtasks. - * - * Generated from protobuf field string type = 3; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Output only. The current state of the subtask. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationSubtask.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the subtask. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationSubtask.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\Migration\V2\MigrationSubtask\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Rpc\ErrorInfo|null - */ - public function getProcessingError() - { - return $this->processing_error; - } - - public function hasProcessingError() - { - return isset($this->processing_error); - } - - public function clearProcessingError() - { - unset($this->processing_error); - } - - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Rpc\ErrorInfo $var - * @return $this - */ - public function setProcessingError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\ErrorInfo::class); - $this->processing_error = $var; - - return $this; - } - - /** - * Output only. Provides details to errors and issues encountered while - * processing the subtask. Presence of error details does not mean that the - * subtask failed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ResourceErrorDetail resource_error_details = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceErrorDetails() - { - return $this->resource_error_details; - } - - /** - * Output only. Provides details to errors and issues encountered while - * processing the subtask. Presence of error details does not mean that the - * subtask failed. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ResourceErrorDetail resource_error_details = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\BigQuery\Migration\V2\ResourceErrorDetail>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceErrorDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\ResourceErrorDetail::class); - $this->resource_error_details = $arr; - - return $this; - } - - /** - * The number or resources with errors. Note: This is not the total - * number of errors as each resource can have more than one error. - * This is used to indicate truncation by having a `resource_error_count` - * that is higher than the size of `resource_error_details`. - * - * Generated from protobuf field int32 resource_error_count = 13; - * @return int - */ - public function getResourceErrorCount() - { - return $this->resource_error_count; - } - - /** - * The number or resources with errors. Note: This is not the total - * number of errors as each resource can have more than one error. - * This is used to indicate truncation by having a `resource_error_count` - * that is higher than the size of `resource_error_details`. - * - * Generated from protobuf field int32 resource_error_count = 13; - * @param int $var - * @return $this - */ - public function setResourceErrorCount($var) - { - GPBUtil::checkInt32($var); - $this->resource_error_count = $var; - - return $this; - } - - /** - * Time when the subtask was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time when the subtask was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time when the subtask was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 8; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastUpdateTime() - { - return $this->last_update_time; - } - - public function hasLastUpdateTime() - { - return isset($this->last_update_time); - } - - public function clearLastUpdateTime() - { - unset($this->last_update_time); - } - - /** - * Time when the subtask was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 8; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_update_time = $var; - - return $this; - } - - /** - * The metrics for the subtask. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.TimeSeries metrics = 11; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metrics for the subtask. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.TimeSeries metrics = 11; - * @param array<\Google\Cloud\BigQuery\Migration\V2\TimeSeries>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\TimeSeries::class); - $this->metrics = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask/State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask/State.php deleted file mode 100644 index 69f3698eaf48..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask/State.php +++ /dev/null @@ -1,94 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationSubtask.State - */ -class State -{ - /** - * The state is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The subtask is ready, i.e. it is ready for execution. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The subtask is running, i.e. it is assigned to a worker for execution. - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * The subtask finished successfully. - * - * Generated from protobuf enum SUCCEEDED = 3; - */ - const SUCCEEDED = 3; - /** - * The subtask finished unsuccessfully. - * - * Generated from protobuf enum FAILED = 4; - */ - const FAILED = 4; - /** - * The subtask is paused, i.e., it will not be scheduled. If it was already - * assigned,it might still finish but no new lease renewals will be granted. - * - * Generated from protobuf enum PAUSED = 5; - */ - const PAUSED = 5; - /** - * The subtask is pending a dependency. It will be scheduled once its - * dependencies are done. - * - * Generated from protobuf enum PENDING_DEPENDENCY = 6; - */ - const PENDING_DEPENDENCY = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::RUNNING => 'RUNNING', - self::SUCCEEDED => 'SUCCEEDED', - self::FAILED => 'FAILED', - self::PAUSED => 'PAUSED', - self::PENDING_DEPENDENCY => 'PENDING_DEPENDENCY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BigQuery\Migration\V2\MigrationSubtask_State::class); - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask_State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask_State.php deleted file mode 100644 index 7a24bf0c186d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationSubtask_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationTask - */ -class MigrationTask extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Immutable. The unique identifier for the migration task. The - * ID is server-generated. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $id = ''; - /** - * The type of the task. This must be one of the supported task types: - * Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, - * Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, - * Translation_Snowflake2BQ, Translation_Netezza2BQ, - * Translation_AzureSynapse2BQ, Translation_Vertica2BQ, - * Translation_SQLServer2BQ, Translation_Presto2BQ, Translation_MySQL2BQ, - * Translation_Postgresql2BQ. - * - * Generated from protobuf field string type = 2; - */ - protected $type = ''; - /** - * Output only. The current state of the task. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationTask.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $processing_error = null; - /** - * Time when the task was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - */ - protected $create_time = null; - /** - * Time when the task was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 7; - */ - protected $last_update_time = null; - protected $task_details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\Migration\V2\TranslationConfigDetails $translation_config_details - * Task configuration for Batch SQL Translation. - * @type string $id - * Output only. Immutable. The unique identifier for the migration task. The - * ID is server-generated. - * @type string $type - * The type of the task. This must be one of the supported task types: - * Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, - * Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, - * Translation_Snowflake2BQ, Translation_Netezza2BQ, - * Translation_AzureSynapse2BQ, Translation_Vertica2BQ, - * Translation_SQLServer2BQ, Translation_Presto2BQ, Translation_MySQL2BQ, - * Translation_Postgresql2BQ. - * @type int $state - * Output only. The current state of the task. - * @type \Google\Rpc\ErrorInfo $processing_error - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * @type \Google\Protobuf\Timestamp $create_time - * Time when the task was created. - * @type \Google\Protobuf\Timestamp $last_update_time - * Time when the task was last updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationEntities::initOnce(); - parent::__construct($data); - } - - /** - * Task configuration for Batch SQL Translation. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TranslationConfigDetails translation_config_details = 14; - * @return \Google\Cloud\BigQuery\Migration\V2\TranslationConfigDetails|null - */ - public function getTranslationConfigDetails() - { - return $this->readOneof(14); - } - - public function hasTranslationConfigDetails() - { - return $this->hasOneof(14); - } - - /** - * Task configuration for Batch SQL Translation. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TranslationConfigDetails translation_config_details = 14; - * @param \Google\Cloud\BigQuery\Migration\V2\TranslationConfigDetails $var - * @return $this - */ - public function setTranslationConfigDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\TranslationConfigDetails::class); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * Output only. Immutable. The unique identifier for the migration task. The - * ID is server-generated. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Output only. Immutable. The unique identifier for the migration task. The - * ID is server-generated. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The type of the task. This must be one of the supported task types: - * Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, - * Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, - * Translation_Snowflake2BQ, Translation_Netezza2BQ, - * Translation_AzureSynapse2BQ, Translation_Vertica2BQ, - * Translation_SQLServer2BQ, Translation_Presto2BQ, Translation_MySQL2BQ, - * Translation_Postgresql2BQ. - * - * Generated from protobuf field string type = 2; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The type of the task. This must be one of the supported task types: - * Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, - * Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, - * Translation_Snowflake2BQ, Translation_Netezza2BQ, - * Translation_AzureSynapse2BQ, Translation_Vertica2BQ, - * Translation_SQLServer2BQ, Translation_Presto2BQ, Translation_MySQL2BQ, - * Translation_Postgresql2BQ. - * - * Generated from protobuf field string type = 2; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Output only. The current state of the task. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationTask.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of the task. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationTask.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\Migration\V2\MigrationTask\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Rpc\ErrorInfo|null - */ - public function getProcessingError() - { - return $this->processing_error; - } - - public function hasProcessingError() - { - return isset($this->processing_error); - } - - public function clearProcessingError() - { - unset($this->processing_error); - } - - /** - * Output only. An explanation that may be populated when the task is in - * FAILED state. - * - * Generated from protobuf field .google.rpc.ErrorInfo processing_error = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Rpc\ErrorInfo $var - * @return $this - */ - public function setProcessingError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\ErrorInfo::class); - $this->processing_error = $var; - - return $this; - } - - /** - * Time when the task was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time when the task was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time when the task was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 7; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastUpdateTime() - { - return $this->last_update_time; - } - - public function hasLastUpdateTime() - { - return isset($this->last_update_time); - } - - public function clearLastUpdateTime() - { - unset($this->last_update_time); - } - - /** - * Time when the task was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 7; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_update_time = $var; - - return $this; - } - - /** - * @return string - */ - public function getTaskDetails() - { - return $this->whichOneof("task_details"); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask/State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask/State.php deleted file mode 100644 index e55eb83b5525..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask/State.php +++ /dev/null @@ -1,93 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationTask.State - */ -class State -{ - /** - * The state is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The task is waiting for orchestration. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * The task is assigned to an orchestrator. - * - * Generated from protobuf enum ORCHESTRATING = 2; - */ - const ORCHESTRATING = 2; - /** - * The task is running, i.e. its subtasks are ready for execution. - * - * Generated from protobuf enum RUNNING = 3; - */ - const RUNNING = 3; - /** - * Tha task is paused. Assigned subtasks can continue, but no new subtasks - * will be scheduled. - * - * Generated from protobuf enum PAUSED = 4; - */ - const PAUSED = 4; - /** - * The task finished successfully. - * - * Generated from protobuf enum SUCCEEDED = 5; - */ - const SUCCEEDED = 5; - /** - * The task finished unsuccessfully. - * - * Generated from protobuf enum FAILED = 6; - */ - const FAILED = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::ORCHESTRATING => 'ORCHESTRATING', - self::RUNNING => 'RUNNING', - self::PAUSED => 'PAUSED', - self::SUCCEEDED => 'SUCCEEDED', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BigQuery\Migration\V2\MigrationTask_State::class); - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask_State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask_State.php deleted file mode 100644 index d63c1335d8d5..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationTask_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationWorkflow - */ -class MigrationWorkflow extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Immutable. The unique identifier for the migration workflow. - * The ID is server-generated. - * Example: `projects/123/locations/us/workflows/345` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * The display name of the workflow. This can be set to give a workflow - * a descriptive name. There is no guarantee or enforcement of uniqueness. - * - * Generated from protobuf field string display_name = 6; - */ - protected $display_name = ''; - /** - * The tasks in a workflow in a named map. The name (i.e. key) has no - * meaning and is merely a convenient way to address a specific task - * in a workflow. - * - * Generated from protobuf field map tasks = 2; - */ - private $tasks; - /** - * Output only. That status of the workflow. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Time when the workflow was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4; - */ - protected $create_time = null; - /** - * Time when the workflow was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 5; - */ - protected $last_update_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Immutable. The unique identifier for the migration workflow. - * The ID is server-generated. - * Example: `projects/123/locations/us/workflows/345` - * @type string $display_name - * The display name of the workflow. This can be set to give a workflow - * a descriptive name. There is no guarantee or enforcement of uniqueness. - * @type array|\Google\Protobuf\Internal\MapField $tasks - * The tasks in a workflow in a named map. The name (i.e. key) has no - * meaning and is merely a convenient way to address a specific task - * in a workflow. - * @type int $state - * Output only. That status of the workflow. - * @type \Google\Protobuf\Timestamp $create_time - * Time when the workflow was created. - * @type \Google\Protobuf\Timestamp $last_update_time - * Time when the workflow was last updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationEntities::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Immutable. The unique identifier for the migration workflow. - * The ID is server-generated. - * Example: `projects/123/locations/us/workflows/345` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Immutable. The unique identifier for the migration workflow. - * The ID is server-generated. - * Example: `projects/123/locations/us/workflows/345` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The display name of the workflow. This can be set to give a workflow - * a descriptive name. There is no guarantee or enforcement of uniqueness. - * - * Generated from protobuf field string display_name = 6; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The display name of the workflow. This can be set to give a workflow - * a descriptive name. There is no guarantee or enforcement of uniqueness. - * - * Generated from protobuf field string display_name = 6; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The tasks in a workflow in a named map. The name (i.e. key) has no - * meaning and is merely a convenient way to address a specific task - * in a workflow. - * - * Generated from protobuf field map tasks = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getTasks() - { - return $this->tasks; - } - - /** - * The tasks in a workflow in a named map. The name (i.e. key) has no - * meaning and is merely a convenient way to address a specific task - * in a workflow. - * - * Generated from protobuf field map tasks = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setTasks($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\MigrationTask::class); - $this->tasks = $arr; - - return $this; - } - - /** - * Output only. That status of the workflow. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. That status of the workflow. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.MigrationWorkflow.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow\State::class); - $this->state = $var; - - return $this; - } - - /** - * Time when the workflow was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time when the workflow was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time when the workflow was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLastUpdateTime() - { - return $this->last_update_time; - } - - public function hasLastUpdateTime() - { - return isset($this->last_update_time); - } - - public function clearLastUpdateTime() - { - unset($this->last_update_time); - } - - /** - * Time when the workflow was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLastUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->last_update_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow/State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow/State.php deleted file mode 100644 index a3d08c0f69bd..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow/State.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.bigquery.migration.v2.MigrationWorkflow.State - */ -class State -{ - /** - * Workflow state is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Workflow is in draft status, i.e. tasks are not yet eligible for - * execution. - * - * Generated from protobuf enum DRAFT = 1; - */ - const DRAFT = 1; - /** - * Workflow is running (i.e. tasks are eligible for execution). - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * Workflow is paused. Tasks currently in progress may continue, but no - * further tasks will be scheduled. - * - * Generated from protobuf enum PAUSED = 3; - */ - const PAUSED = 3; - /** - * Workflow is complete. There should not be any task in a non-terminal - * state, but if they are (e.g. forced termination), they will not be - * scheduled. - * - * Generated from protobuf enum COMPLETED = 4; - */ - const COMPLETED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::DRAFT => 'DRAFT', - self::RUNNING => 'RUNNING', - self::PAUSED => 'PAUSED', - self::COMPLETED => 'COMPLETED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow_State::class); - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow_State.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow_State.php deleted file mode 100644 index 43332b365993..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/MigrationWorkflow_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.migration.v2.MySQLDialect - */ -class MySQLDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey.php deleted file mode 100644 index 685893ad9db5..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.bigquery.migration.v2.NameMappingKey - */ -class NameMappingKey extends \Google\Protobuf\Internal\Message -{ - /** - * The type of object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey.Type type = 1; - */ - protected $type = 0; - /** - * The database name (BigQuery project ID equivalent in the source data - * warehouse). - * - * Generated from protobuf field string database = 2; - */ - protected $database = ''; - /** - * The schema name (BigQuery dataset equivalent in the source data warehouse). - * - * Generated from protobuf field string schema = 3; - */ - protected $schema = ''; - /** - * The relation name (BigQuery table or view equivalent in the source data - * warehouse). - * - * Generated from protobuf field string relation = 4; - */ - protected $relation = ''; - /** - * The attribute name (BigQuery column equivalent in the source data - * warehouse). - * - * Generated from protobuf field string attribute = 5; - */ - protected $attribute = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The type of object that is being mapped. - * @type string $database - * The database name (BigQuery project ID equivalent in the source data - * warehouse). - * @type string $schema - * The schema name (BigQuery dataset equivalent in the source data warehouse). - * @type string $relation - * The relation name (BigQuery table or view equivalent in the source data - * warehouse). - * @type string $attribute - * The attribute name (BigQuery column equivalent in the source data - * warehouse). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The type of object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey.Type type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey.Type type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\Migration\V2\NameMappingKey\Type::class); - $this->type = $var; - - return $this; - } - - /** - * The database name (BigQuery project ID equivalent in the source data - * warehouse). - * - * Generated from protobuf field string database = 2; - * @return string - */ - public function getDatabase() - { - return $this->database; - } - - /** - * The database name (BigQuery project ID equivalent in the source data - * warehouse). - * - * Generated from protobuf field string database = 2; - * @param string $var - * @return $this - */ - public function setDatabase($var) - { - GPBUtil::checkString($var, True); - $this->database = $var; - - return $this; - } - - /** - * The schema name (BigQuery dataset equivalent in the source data warehouse). - * - * Generated from protobuf field string schema = 3; - * @return string - */ - public function getSchema() - { - return $this->schema; - } - - /** - * The schema name (BigQuery dataset equivalent in the source data warehouse). - * - * Generated from protobuf field string schema = 3; - * @param string $var - * @return $this - */ - public function setSchema($var) - { - GPBUtil::checkString($var, True); - $this->schema = $var; - - return $this; - } - - /** - * The relation name (BigQuery table or view equivalent in the source data - * warehouse). - * - * Generated from protobuf field string relation = 4; - * @return string - */ - public function getRelation() - { - return $this->relation; - } - - /** - * The relation name (BigQuery table or view equivalent in the source data - * warehouse). - * - * Generated from protobuf field string relation = 4; - * @param string $var - * @return $this - */ - public function setRelation($var) - { - GPBUtil::checkString($var, True); - $this->relation = $var; - - return $this; - } - - /** - * The attribute name (BigQuery column equivalent in the source data - * warehouse). - * - * Generated from protobuf field string attribute = 5; - * @return string - */ - public function getAttribute() - { - return $this->attribute; - } - - /** - * The attribute name (BigQuery column equivalent in the source data - * warehouse). - * - * Generated from protobuf field string attribute = 5; - * @param string $var - * @return $this - */ - public function setAttribute($var) - { - GPBUtil::checkString($var, True); - $this->attribute = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey/Type.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey/Type.php deleted file mode 100644 index dac0840dcc6e..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey/Type.php +++ /dev/null @@ -1,103 +0,0 @@ -google.cloud.bigquery.migration.v2.NameMappingKey.Type - */ -class Type -{ - /** - * Unspecified name mapping type. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * The object being mapped is a database. - * - * Generated from protobuf enum DATABASE = 1; - */ - const DATABASE = 1; - /** - * The object being mapped is a schema. - * - * Generated from protobuf enum SCHEMA = 2; - */ - const SCHEMA = 2; - /** - * The object being mapped is a relation. - * - * Generated from protobuf enum RELATION = 3; - */ - const RELATION = 3; - /** - * The object being mapped is an attribute. - * - * Generated from protobuf enum ATTRIBUTE = 4; - */ - const ATTRIBUTE = 4; - /** - * The object being mapped is a relation alias. - * - * Generated from protobuf enum RELATION_ALIAS = 5; - */ - const RELATION_ALIAS = 5; - /** - * The object being mapped is a an attribute alias. - * - * Generated from protobuf enum ATTRIBUTE_ALIAS = 6; - */ - const ATTRIBUTE_ALIAS = 6; - /** - * The object being mapped is a function. - * - * Generated from protobuf enum FUNCTION = 7; - */ - const PBFUNCTION = 7; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::DATABASE => 'DATABASE', - self::SCHEMA => 'SCHEMA', - self::RELATION => 'RELATION', - self::ATTRIBUTE => 'ATTRIBUTE', - self::RELATION_ALIAS => 'RELATION_ALIAS', - self::ATTRIBUTE_ALIAS => 'ATTRIBUTE_ALIAS', - self::PBFUNCTION => 'FUNCTION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\BigQuery\Migration\V2\NameMappingKey_Type::class); - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey_Type.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey_Type.php deleted file mode 100644 index 9f197412e0af..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NameMappingKey_Type.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.migration.v2.NameMappingValue - */ -class NameMappingValue extends \Google\Protobuf\Internal\Message -{ - /** - * The database name (BigQuery project ID equivalent in the target data - * warehouse). - * - * Generated from protobuf field string database = 1; - */ - protected $database = ''; - /** - * The schema name (BigQuery dataset equivalent in the target data warehouse). - * - * Generated from protobuf field string schema = 2; - */ - protected $schema = ''; - /** - * The relation name (BigQuery table or view equivalent in the target data - * warehouse). - * - * Generated from protobuf field string relation = 3; - */ - protected $relation = ''; - /** - * The attribute name (BigQuery column equivalent in the target data - * warehouse). - * - * Generated from protobuf field string attribute = 4; - */ - protected $attribute = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $database - * The database name (BigQuery project ID equivalent in the target data - * warehouse). - * @type string $schema - * The schema name (BigQuery dataset equivalent in the target data warehouse). - * @type string $relation - * The relation name (BigQuery table or view equivalent in the target data - * warehouse). - * @type string $attribute - * The attribute name (BigQuery column equivalent in the target data - * warehouse). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The database name (BigQuery project ID equivalent in the target data - * warehouse). - * - * Generated from protobuf field string database = 1; - * @return string - */ - public function getDatabase() - { - return $this->database; - } - - /** - * The database name (BigQuery project ID equivalent in the target data - * warehouse). - * - * Generated from protobuf field string database = 1; - * @param string $var - * @return $this - */ - public function setDatabase($var) - { - GPBUtil::checkString($var, True); - $this->database = $var; - - return $this; - } - - /** - * The schema name (BigQuery dataset equivalent in the target data warehouse). - * - * Generated from protobuf field string schema = 2; - * @return string - */ - public function getSchema() - { - return $this->schema; - } - - /** - * The schema name (BigQuery dataset equivalent in the target data warehouse). - * - * Generated from protobuf field string schema = 2; - * @param string $var - * @return $this - */ - public function setSchema($var) - { - GPBUtil::checkString($var, True); - $this->schema = $var; - - return $this; - } - - /** - * The relation name (BigQuery table or view equivalent in the target data - * warehouse). - * - * Generated from protobuf field string relation = 3; - * @return string - */ - public function getRelation() - { - return $this->relation; - } - - /** - * The relation name (BigQuery table or view equivalent in the target data - * warehouse). - * - * Generated from protobuf field string relation = 3; - * @param string $var - * @return $this - */ - public function setRelation($var) - { - GPBUtil::checkString($var, True); - $this->relation = $var; - - return $this; - } - - /** - * The attribute name (BigQuery column equivalent in the target data - * warehouse). - * - * Generated from protobuf field string attribute = 4; - * @return string - */ - public function getAttribute() - { - return $this->attribute; - } - - /** - * The attribute name (BigQuery column equivalent in the target data - * warehouse). - * - * Generated from protobuf field string attribute = 4; - * @param string $var - * @return $this - */ - public function setAttribute($var) - { - GPBUtil::checkString($var, True); - $this->attribute = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NetezzaDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NetezzaDialect.php deleted file mode 100644 index 1a722f2364c1..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/NetezzaDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.NetezzaDialect - */ -class NetezzaDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMapping.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMapping.php deleted file mode 100644 index 8f6205ed4689..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMapping.php +++ /dev/null @@ -1,122 +0,0 @@ -google.cloud.bigquery.migration.v2.ObjectNameMapping - */ -class ObjectNameMapping extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the object in source that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey source = 1; - */ - protected $source = null; - /** - * The desired target name of the object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingValue target = 2; - */ - protected $target = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\Migration\V2\NameMappingKey $source - * The name of the object in source that is being mapped. - * @type \Google\Cloud\BigQuery\Migration\V2\NameMappingValue $target - * The desired target name of the object that is being mapped. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The name of the object in source that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey source = 1; - * @return \Google\Cloud\BigQuery\Migration\V2\NameMappingKey|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * The name of the object in source that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingKey source = 1; - * @param \Google\Cloud\BigQuery\Migration\V2\NameMappingKey $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\NameMappingKey::class); - $this->source = $var; - - return $this; - } - - /** - * The desired target name of the object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingValue target = 2; - * @return \Google\Cloud\BigQuery\Migration\V2\NameMappingValue|null - */ - public function getTarget() - { - return $this->target; - } - - public function hasTarget() - { - return isset($this->target); - } - - public function clearTarget() - { - unset($this->target); - } - - /** - * The desired target name of the object that is being mapped. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.NameMappingValue target = 2; - * @param \Google\Cloud\BigQuery\Migration\V2\NameMappingValue $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\NameMappingValue::class); - $this->target = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMappingList.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMappingList.php deleted file mode 100644 index 6dba3633d75d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ObjectNameMappingList.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.bigquery.migration.v2.ObjectNameMappingList - */ -class ObjectNameMappingList extends \Google\Protobuf\Internal\Message -{ - /** - * The elements of the object name map. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ObjectNameMapping name_map = 1; - */ - private $name_map; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\BigQuery\Migration\V2\ObjectNameMapping>|\Google\Protobuf\Internal\RepeatedField $name_map - * The elements of the object name map. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The elements of the object name map. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ObjectNameMapping name_map = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNameMap() - { - return $this->name_map; - } - - /** - * The elements of the object name map. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ObjectNameMapping name_map = 1; - * @param array<\Google\Cloud\BigQuery\Migration\V2\ObjectNameMapping>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNameMap($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\ObjectNameMapping::class); - $this->name_map = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/OracleDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/OracleDialect.php deleted file mode 100644 index 3d3708230e6d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/OracleDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.OracleDialect - */ -class OracleDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Point.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Point.php deleted file mode 100644 index 19294ba7a81d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/Point.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.bigquery.migration.v2.Point - */ -class Point extends \Google\Protobuf\Internal\Message -{ - /** - * The time interval to which the data point applies. For `GAUGE` metrics, - * the start time does not need to be supplied, but if it is supplied, it must - * equal the end time. For `DELTA` metrics, the start and end time should - * specify a non-zero interval, with subsequent points specifying contiguous - * and non-overlapping intervals. For `CUMULATIVE` metrics, the start and end - * time should specify a non-zero interval, with subsequent points specifying - * the same start time and increasing end times, until an event resets the - * cumulative value to zero and sets a new start time for the following - * points. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TimeInterval interval = 1; - */ - protected $interval = null; - /** - * The value of the data point. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TypedValue value = 2; - */ - protected $value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\BigQuery\Migration\V2\TimeInterval $interval - * The time interval to which the data point applies. For `GAUGE` metrics, - * the start time does not need to be supplied, but if it is supplied, it must - * equal the end time. For `DELTA` metrics, the start and end time should - * specify a non-zero interval, with subsequent points specifying contiguous - * and non-overlapping intervals. For `CUMULATIVE` metrics, the start and end - * time should specify a non-zero interval, with subsequent points specifying - * the same start time and increasing end times, until an event resets the - * cumulative value to zero and sets a new start time for the following - * points. - * @type \Google\Cloud\BigQuery\Migration\V2\TypedValue $value - * The value of the data point. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationMetrics::initOnce(); - parent::__construct($data); - } - - /** - * The time interval to which the data point applies. For `GAUGE` metrics, - * the start time does not need to be supplied, but if it is supplied, it must - * equal the end time. For `DELTA` metrics, the start and end time should - * specify a non-zero interval, with subsequent points specifying contiguous - * and non-overlapping intervals. For `CUMULATIVE` metrics, the start and end - * time should specify a non-zero interval, with subsequent points specifying - * the same start time and increasing end times, until an event resets the - * cumulative value to zero and sets a new start time for the following - * points. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TimeInterval interval = 1; - * @return \Google\Cloud\BigQuery\Migration\V2\TimeInterval|null - */ - public function getInterval() - { - return $this->interval; - } - - public function hasInterval() - { - return isset($this->interval); - } - - public function clearInterval() - { - unset($this->interval); - } - - /** - * The time interval to which the data point applies. For `GAUGE` metrics, - * the start time does not need to be supplied, but if it is supplied, it must - * equal the end time. For `DELTA` metrics, the start and end time should - * specify a non-zero interval, with subsequent points specifying contiguous - * and non-overlapping intervals. For `CUMULATIVE` metrics, the start and end - * time should specify a non-zero interval, with subsequent points specifying - * the same start time and increasing end times, until an event resets the - * cumulative value to zero and sets a new start time for the following - * points. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TimeInterval interval = 1; - * @param \Google\Cloud\BigQuery\Migration\V2\TimeInterval $var - * @return $this - */ - public function setInterval($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\TimeInterval::class); - $this->interval = $var; - - return $this; - } - - /** - * The value of the data point. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TypedValue value = 2; - * @return \Google\Cloud\BigQuery\Migration\V2\TypedValue|null - */ - public function getValue() - { - return $this->value; - } - - public function hasValue() - { - return isset($this->value); - } - - public function clearValue() - { - unset($this->value); - } - - /** - * The value of the data point. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TypedValue value = 2; - * @param \Google\Cloud\BigQuery\Migration\V2\TypedValue $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\TypedValue::class); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PostgresqlDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PostgresqlDialect.php deleted file mode 100644 index 9be7ec3ba359..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PostgresqlDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.PostgresqlDialect - */ -class PostgresqlDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PrestoDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PrestoDialect.php deleted file mode 100644 index ede9e320ec01..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/PrestoDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.PrestoDialect - */ -class PrestoDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/RedshiftDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/RedshiftDialect.php deleted file mode 100644 index a2130a53a9af..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/RedshiftDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.RedshiftDialect - */ -class RedshiftDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ResourceErrorDetail.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ResourceErrorDetail.php deleted file mode 100644 index a28217d83d87..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/ResourceErrorDetail.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.bigquery.migration.v2.ResourceErrorDetail - */ -class ResourceErrorDetail extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Information about the resource where the error is located. - * - * Generated from protobuf field .google.rpc.ResourceInfo resource_info = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource_info = null; - /** - * Required. The error details for the resource. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ErrorDetail error_details = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $error_details; - /** - * Required. How many errors there are in total for the resource. Truncation - * can be indicated by having an `error_count` that is higher than the size of - * `error_details`. - * - * Generated from protobuf field int32 error_count = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $error_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Rpc\ResourceInfo $resource_info - * Required. Information about the resource where the error is located. - * @type array<\Google\Cloud\BigQuery\Migration\V2\ErrorDetail>|\Google\Protobuf\Internal\RepeatedField $error_details - * Required. The error details for the resource. - * @type int $error_count - * Required. How many errors there are in total for the resource. Truncation - * can be indicated by having an `error_count` that is higher than the size of - * `error_details`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationErrorDetails::initOnce(); - parent::__construct($data); - } - - /** - * Required. Information about the resource where the error is located. - * - * Generated from protobuf field .google.rpc.ResourceInfo resource_info = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Rpc\ResourceInfo|null - */ - public function getResourceInfo() - { - return $this->resource_info; - } - - public function hasResourceInfo() - { - return isset($this->resource_info); - } - - public function clearResourceInfo() - { - unset($this->resource_info); - } - - /** - * Required. Information about the resource where the error is located. - * - * Generated from protobuf field .google.rpc.ResourceInfo resource_info = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Rpc\ResourceInfo $var - * @return $this - */ - public function setResourceInfo($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\ResourceInfo::class); - $this->resource_info = $var; - - return $this; - } - - /** - * Required. The error details for the resource. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ErrorDetail error_details = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getErrorDetails() - { - return $this->error_details; - } - - /** - * Required. The error details for the resource. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.ErrorDetail error_details = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\BigQuery\Migration\V2\ErrorDetail>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setErrorDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\ErrorDetail::class); - $this->error_details = $arr; - - return $this; - } - - /** - * Required. How many errors there are in total for the resource. Truncation - * can be indicated by having an `error_count` that is higher than the size of - * `error_details`. - * - * Generated from protobuf field int32 error_count = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getErrorCount() - { - return $this->error_count; - } - - /** - * Required. How many errors there are in total for the resource. Truncation - * can be indicated by having an `error_count` that is higher than the size of - * `error_details`. - * - * Generated from protobuf field int32 error_count = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setErrorCount($var) - { - GPBUtil::checkInt32($var); - $this->error_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SQLServerDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SQLServerDialect.php deleted file mode 100644 index f535d05ac4af..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SQLServerDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.SQLServerDialect - */ -class SQLServerDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SnowflakeDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SnowflakeDialect.php deleted file mode 100644 index b0edf5c26f67..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SnowflakeDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.SnowflakeDialect - */ -class SnowflakeDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SourceEnv.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SourceEnv.php deleted file mode 100644 index ad5d668878ea..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SourceEnv.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.bigquery.migration.v2.SourceEnv - */ -class SourceEnv extends \Google\Protobuf\Internal\Message -{ - /** - * The default database name to fully qualify SQL objects when their database - * name is missing. - * - * Generated from protobuf field string default_database = 1; - */ - protected $default_database = ''; - /** - * The schema search path. When SQL objects are missing schema name, - * translation engine will search through this list to find the value. - * - * Generated from protobuf field repeated string schema_search_path = 2; - */ - private $schema_search_path; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $default_database - * The default database name to fully qualify SQL objects when their database - * name is missing. - * @type array|\Google\Protobuf\Internal\RepeatedField $schema_search_path - * The schema search path. When SQL objects are missing schema name, - * translation engine will search through this list to find the value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The default database name to fully qualify SQL objects when their database - * name is missing. - * - * Generated from protobuf field string default_database = 1; - * @return string - */ - public function getDefaultDatabase() - { - return $this->default_database; - } - - /** - * The default database name to fully qualify SQL objects when their database - * name is missing. - * - * Generated from protobuf field string default_database = 1; - * @param string $var - * @return $this - */ - public function setDefaultDatabase($var) - { - GPBUtil::checkString($var, True); - $this->default_database = $var; - - return $this; - } - - /** - * The schema search path. When SQL objects are missing schema name, - * translation engine will search through this list to find the value. - * - * Generated from protobuf field repeated string schema_search_path = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSchemaSearchPath() - { - return $this->schema_search_path; - } - - /** - * The schema search path. When SQL objects are missing schema name, - * translation engine will search through this list to find the value. - * - * Generated from protobuf field repeated string schema_search_path = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSchemaSearchPath($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->schema_search_path = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SparkSQLDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SparkSQLDialect.php deleted file mode 100644 index a933fa68324d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/SparkSQLDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.SparkSQLDialect - */ -class SparkSQLDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/StartMigrationWorkflowRequest.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/StartMigrationWorkflowRequest.php deleted file mode 100644 index 28129d124acf..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/StartMigrationWorkflowRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.bigquery.migration.v2.StartMigrationWorkflowRequest - */ -class StartMigrationWorkflowRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * Please see {@see MigrationServiceClient::migrationWorkflowName()} for help formatting this field. - * - * @return \Google\Cloud\BigQuery\Migration\V2\StartMigrationWorkflowRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect.php deleted file mode 100644 index b50e261eeb92..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.bigquery.migration.v2.TeradataDialect - */ -class TeradataDialect extends \Google\Protobuf\Internal\Message -{ - /** - * Which Teradata sub-dialect mode the user specifies. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TeradataDialect.Mode mode = 1; - */ - protected $mode = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $mode - * Which Teradata sub-dialect mode the user specifies. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * Which Teradata sub-dialect mode the user specifies. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TeradataDialect.Mode mode = 1; - * @return int - */ - public function getMode() - { - return $this->mode; - } - - /** - * Which Teradata sub-dialect mode the user specifies. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.TeradataDialect.Mode mode = 1; - * @param int $var - * @return $this - */ - public function setMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\Migration\V2\TeradataDialect\Mode::class); - $this->mode = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect/Mode.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect/Mode.php deleted file mode 100644 index 8565d3737289..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect/Mode.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.bigquery.migration.v2.TeradataDialect.Mode - */ -class Mode -{ - /** - * Unspecified mode. - * - * Generated from protobuf enum MODE_UNSPECIFIED = 0; - */ - const MODE_UNSPECIFIED = 0; - /** - * Teradata SQL mode. - * - * Generated from protobuf enum SQL = 1; - */ - const SQL = 1; - /** - * BTEQ mode (which includes SQL). - * - * Generated from protobuf enum BTEQ = 2; - */ - const BTEQ = 2; - - private static $valueToName = [ - self::MODE_UNSPECIFIED => 'MODE_UNSPECIFIED', - self::SQL => 'SQL', - self::BTEQ => 'BTEQ', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Mode::class, \Google\Cloud\BigQuery\Migration\V2\TeradataDialect_Mode::class); - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect_Mode.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect_Mode.php deleted file mode 100644 index e2e294b5a03d..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TeradataDialect_Mode.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.bigquery.migration.v2.TimeInterval - */ -class TimeInterval extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The beginning of the time interval. The default value - * for the start time is the end time. The start time must not be - * later than the end time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $start_time = null; - /** - * Required. The end of the time interval. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $start_time - * Optional. The beginning of the time interval. The default value - * for the start time is the end time. The start time must not be - * later than the end time. - * @type \Google\Protobuf\Timestamp $end_time - * Required. The end of the time interval. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationMetrics::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The beginning of the time interval. The default value - * for the start time is the end time. The start time must not be - * later than the end time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Optional. The beginning of the time interval. The default value - * for the start time is the end time. The start time must not be - * later than the end time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Required. The end of the time interval. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Required. The end of the time interval. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TimeSeries.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TimeSeries.php deleted file mode 100644 index 2ea97494c4de..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TimeSeries.php +++ /dev/null @@ -1,213 +0,0 @@ -google.cloud.bigquery.migration.v2.TimeSeries - */ -class TimeSeries extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the metric. - * If the metric is not known by the service yet, it will be auto-created. - * - * Generated from protobuf field string metric = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $metric = ''; - /** - * Required. The value type of the time series. - * - * Generated from protobuf field .google.api.MetricDescriptor.ValueType value_type = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $value_type = 0; - /** - * Optional. The metric kind of the time series. - * If present, it must be the same as the metric kind of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * this field specifies the metric kind of the new descriptor and must be - * either `GAUGE` (the default) or `CUMULATIVE`. - * - * Generated from protobuf field .google.api.MetricDescriptor.MetricKind metric_kind = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $metric_kind = 0; - /** - * Required. The data points of this time series. When listing time series, - * points are returned in reverse time order. - * When creating a time series, this field must contain exactly one point and - * the point's type must be the same as the value type of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * the value type of the descriptor is determined by the point's type, which - * must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.Point points = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $points; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $metric - * Required. The name of the metric. - * If the metric is not known by the service yet, it will be auto-created. - * @type int $value_type - * Required. The value type of the time series. - * @type int $metric_kind - * Optional. The metric kind of the time series. - * If present, it must be the same as the metric kind of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * this field specifies the metric kind of the new descriptor and must be - * either `GAUGE` (the default) or `CUMULATIVE`. - * @type array<\Google\Cloud\BigQuery\Migration\V2\Point>|\Google\Protobuf\Internal\RepeatedField $points - * Required. The data points of this time series. When listing time series, - * points are returned in reverse time order. - * When creating a time series, this field must contain exactly one point and - * the point's type must be the same as the value type of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * the value type of the descriptor is determined by the point's type, which - * must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationMetrics::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the metric. - * If the metric is not known by the service yet, it will be auto-created. - * - * Generated from protobuf field string metric = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getMetric() - { - return $this->metric; - } - - /** - * Required. The name of the metric. - * If the metric is not known by the service yet, it will be auto-created. - * - * Generated from protobuf field string metric = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setMetric($var) - { - GPBUtil::checkString($var, True); - $this->metric = $var; - - return $this; - } - - /** - * Required. The value type of the time series. - * - * Generated from protobuf field .google.api.MetricDescriptor.ValueType value_type = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getValueType() - { - return $this->value_type; - } - - /** - * Required. The value type of the time series. - * - * Generated from protobuf field .google.api.MetricDescriptor.ValueType value_type = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setValueType($var) - { - GPBUtil::checkEnum($var, \Google\Api\MetricDescriptor\ValueType::class); - $this->value_type = $var; - - return $this; - } - - /** - * Optional. The metric kind of the time series. - * If present, it must be the same as the metric kind of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * this field specifies the metric kind of the new descriptor and must be - * either `GAUGE` (the default) or `CUMULATIVE`. - * - * Generated from protobuf field .google.api.MetricDescriptor.MetricKind metric_kind = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMetricKind() - { - return $this->metric_kind; - } - - /** - * Optional. The metric kind of the time series. - * If present, it must be the same as the metric kind of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * this field specifies the metric kind of the new descriptor and must be - * either `GAUGE` (the default) or `CUMULATIVE`. - * - * Generated from protobuf field .google.api.MetricDescriptor.MetricKind metric_kind = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMetricKind($var) - { - GPBUtil::checkEnum($var, \Google\Api\MetricDescriptor\MetricKind::class); - $this->metric_kind = $var; - - return $this; - } - - /** - * Required. The data points of this time series. When listing time series, - * points are returned in reverse time order. - * When creating a time series, this field must contain exactly one point and - * the point's type must be the same as the value type of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * the value type of the descriptor is determined by the point's type, which - * must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.Point points = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPoints() - { - return $this->points; - } - - /** - * Required. The data points of this time series. When listing time series, - * points are returned in reverse time order. - * When creating a time series, this field must contain exactly one point and - * the point's type must be the same as the value type of the associated - * metric. If the associated metric's descriptor must be auto-created, then - * the value type of the descriptor is determined by the point's type, which - * must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. - * - * Generated from protobuf field repeated .google.cloud.bigquery.migration.v2.Point points = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\BigQuery\Migration\V2\Point>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPoints($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\Migration\V2\Point::class); - $this->points = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TranslationConfigDetails.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TranslationConfigDetails.php deleted file mode 100644 index c91f045263cb..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TranslationConfigDetails.php +++ /dev/null @@ -1,326 +0,0 @@ -google.cloud.bigquery.migration.v2.TranslationConfigDetails - */ -class TranslationConfigDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The dialect of the input files. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect source_dialect = 3; - */ - protected $source_dialect = null; - /** - * The target dialect for the engine to translate the input to. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect target_dialect = 4; - */ - protected $target_dialect = null; - /** - * The default source environment values for the translation. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SourceEnv source_env = 6; - */ - protected $source_env = null; - /** - * The indicator to show translation request initiator. - * - * Generated from protobuf field string request_source = 8; - */ - protected $request_source = ''; - protected $source_location; - protected $target_location; - protected $output_name_mapping; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $gcs_source_path - * The Cloud Storage path for a directory of files to translate in a task. - * @type string $gcs_target_path - * The Cloud Storage path to write back the corresponding input files to. - * @type \Google\Cloud\BigQuery\Migration\V2\ObjectNameMappingList $name_mapping_list - * The mapping of objects to their desired output names in list form. - * @type \Google\Cloud\BigQuery\Migration\V2\Dialect $source_dialect - * The dialect of the input files. - * @type \Google\Cloud\BigQuery\Migration\V2\Dialect $target_dialect - * The target dialect for the engine to translate the input to. - * @type \Google\Cloud\BigQuery\Migration\V2\SourceEnv $source_env - * The default source environment values for the translation. - * @type string $request_source - * The indicator to show translation request initiator. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage path for a directory of files to translate in a task. - * - * Generated from protobuf field string gcs_source_path = 1; - * @return string - */ - public function getGcsSourcePath() - { - return $this->readOneof(1); - } - - public function hasGcsSourcePath() - { - return $this->hasOneof(1); - } - - /** - * The Cloud Storage path for a directory of files to translate in a task. - * - * Generated from protobuf field string gcs_source_path = 1; - * @param string $var - * @return $this - */ - public function setGcsSourcePath($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The Cloud Storage path to write back the corresponding input files to. - * - * Generated from protobuf field string gcs_target_path = 2; - * @return string - */ - public function getGcsTargetPath() - { - return $this->readOneof(2); - } - - public function hasGcsTargetPath() - { - return $this->hasOneof(2); - } - - /** - * The Cloud Storage path to write back the corresponding input files to. - * - * Generated from protobuf field string gcs_target_path = 2; - * @param string $var - * @return $this - */ - public function setGcsTargetPath($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The mapping of objects to their desired output names in list form. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.ObjectNameMappingList name_mapping_list = 5; - * @return \Google\Cloud\BigQuery\Migration\V2\ObjectNameMappingList|null - */ - public function getNameMappingList() - { - return $this->readOneof(5); - } - - public function hasNameMappingList() - { - return $this->hasOneof(5); - } - - /** - * The mapping of objects to their desired output names in list form. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.ObjectNameMappingList name_mapping_list = 5; - * @param \Google\Cloud\BigQuery\Migration\V2\ObjectNameMappingList $var - * @return $this - */ - public function setNameMappingList($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\ObjectNameMappingList::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * The dialect of the input files. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect source_dialect = 3; - * @return \Google\Cloud\BigQuery\Migration\V2\Dialect|null - */ - public function getSourceDialect() - { - return $this->source_dialect; - } - - public function hasSourceDialect() - { - return isset($this->source_dialect); - } - - public function clearSourceDialect() - { - unset($this->source_dialect); - } - - /** - * The dialect of the input files. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect source_dialect = 3; - * @param \Google\Cloud\BigQuery\Migration\V2\Dialect $var - * @return $this - */ - public function setSourceDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\Dialect::class); - $this->source_dialect = $var; - - return $this; - } - - /** - * The target dialect for the engine to translate the input to. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect target_dialect = 4; - * @return \Google\Cloud\BigQuery\Migration\V2\Dialect|null - */ - public function getTargetDialect() - { - return $this->target_dialect; - } - - public function hasTargetDialect() - { - return isset($this->target_dialect); - } - - public function clearTargetDialect() - { - unset($this->target_dialect); - } - - /** - * The target dialect for the engine to translate the input to. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.Dialect target_dialect = 4; - * @param \Google\Cloud\BigQuery\Migration\V2\Dialect $var - * @return $this - */ - public function setTargetDialect($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\Dialect::class); - $this->target_dialect = $var; - - return $this; - } - - /** - * The default source environment values for the translation. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SourceEnv source_env = 6; - * @return \Google\Cloud\BigQuery\Migration\V2\SourceEnv|null - */ - public function getSourceEnv() - { - return $this->source_env; - } - - public function hasSourceEnv() - { - return isset($this->source_env); - } - - public function clearSourceEnv() - { - unset($this->source_env); - } - - /** - * The default source environment values for the translation. - * - * Generated from protobuf field .google.cloud.bigquery.migration.v2.SourceEnv source_env = 6; - * @param \Google\Cloud\BigQuery\Migration\V2\SourceEnv $var - * @return $this - */ - public function setSourceEnv($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\BigQuery\Migration\V2\SourceEnv::class); - $this->source_env = $var; - - return $this; - } - - /** - * The indicator to show translation request initiator. - * - * Generated from protobuf field string request_source = 8; - * @return string - */ - public function getRequestSource() - { - return $this->request_source; - } - - /** - * The indicator to show translation request initiator. - * - * Generated from protobuf field string request_source = 8; - * @param string $var - * @return $this - */ - public function setRequestSource($var) - { - GPBUtil::checkString($var, True); - $this->request_source = $var; - - return $this; - } - - /** - * @return string - */ - public function getSourceLocation() - { - return $this->whichOneof("source_location"); - } - - /** - * @return string - */ - public function getTargetLocation() - { - return $this->whichOneof("target_location"); - } - - /** - * @return string - */ - public function getOutputNameMapping() - { - return $this->whichOneof("output_name_mapping"); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TypedValue.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TypedValue.php deleted file mode 100644 index f1f140446f87..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/TypedValue.php +++ /dev/null @@ -1,213 +0,0 @@ -google.cloud.bigquery.migration.v2.TypedValue - */ -class TypedValue extends \Google\Protobuf\Internal\Message -{ - protected $value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $bool_value - * A Boolean value: `true` or `false`. - * @type int|string $int64_value - * A 64-bit integer. Its range is approximately `+/-9.2x10^18`. - * @type float $double_value - * A 64-bit double-precision floating-point number. Its magnitude - * is approximately `+/-10^(+/-300)` and it has 16 significant digits of - * precision. - * @type string $string_value - * A variable-length string value. - * @type \Google\Api\Distribution $distribution_value - * A distribution value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\MigrationMetrics::initOnce(); - parent::__construct($data); - } - - /** - * A Boolean value: `true` or `false`. - * - * Generated from protobuf field bool bool_value = 1; - * @return bool - */ - public function getBoolValue() - { - return $this->readOneof(1); - } - - public function hasBoolValue() - { - return $this->hasOneof(1); - } - - /** - * A Boolean value: `true` or `false`. - * - * Generated from protobuf field bool bool_value = 1; - * @param bool $var - * @return $this - */ - public function setBoolValue($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A 64-bit integer. Its range is approximately `+/-9.2x10^18`. - * - * Generated from protobuf field int64 int64_value = 2; - * @return int|string - */ - public function getInt64Value() - { - return $this->readOneof(2); - } - - public function hasInt64Value() - { - return $this->hasOneof(2); - } - - /** - * A 64-bit integer. Its range is approximately `+/-9.2x10^18`. - * - * Generated from protobuf field int64 int64_value = 2; - * @param int|string $var - * @return $this - */ - public function setInt64Value($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A 64-bit double-precision floating-point number. Its magnitude - * is approximately `+/-10^(+/-300)` and it has 16 significant digits of - * precision. - * - * Generated from protobuf field double double_value = 3; - * @return float - */ - public function getDoubleValue() - { - return $this->readOneof(3); - } - - public function hasDoubleValue() - { - return $this->hasOneof(3); - } - - /** - * A 64-bit double-precision floating-point number. Its magnitude - * is approximately `+/-10^(+/-300)` and it has 16 significant digits of - * precision. - * - * Generated from protobuf field double double_value = 3; - * @param float $var - * @return $this - */ - public function setDoubleValue($var) - { - GPBUtil::checkDouble($var); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A variable-length string value. - * - * Generated from protobuf field string string_value = 4; - * @return string - */ - public function getStringValue() - { - return $this->readOneof(4); - } - - public function hasStringValue() - { - return $this->hasOneof(4); - } - - /** - * A variable-length string value. - * - * Generated from protobuf field string string_value = 4; - * @param string $var - * @return $this - */ - public function setStringValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A distribution value. - * - * Generated from protobuf field .google.api.Distribution distribution_value = 5; - * @return \Google\Api\Distribution|null - */ - public function getDistributionValue() - { - return $this->readOneof(5); - } - - public function hasDistributionValue() - { - return $this->hasOneof(5); - } - - /** - * A distribution value. - * - * Generated from protobuf field .google.api.Distribution distribution_value = 5; - * @param \Google\Api\Distribution $var - * @return $this - */ - public function setDistributionValue($var) - { - GPBUtil::checkMessage($var, \Google\Api\Distribution::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getValue() - { - return $this->whichOneof("value"); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/VerticaDialect.php b/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/VerticaDialect.php deleted file mode 100644 index c00c7444c8b1..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/proto/src/Google/Cloud/BigQuery/Migration/V2/VerticaDialect.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.bigquery.migration.v2.VerticaDialect - */ -class VerticaDialect extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Bigquery\Migration\V2\TranslationConfig::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/create_migration_workflow.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/create_migration_workflow.php deleted file mode 100644 index d1ef9eeab44a..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/create_migration_workflow.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent) - ->setMigrationWorkflow($migrationWorkflow); - - // Call the API and handle any network failures. - try { - /** @var MigrationWorkflow $response */ - $response = $migrationServiceClient->createMigrationWorkflow($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 = MigrationServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - create_migration_workflow_sample($formattedParent); -} -// [END bigquerymigration_v2_generated_MigrationService_CreateMigrationWorkflow_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/delete_migration_workflow.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/delete_migration_workflow.php deleted file mode 100644 index 37379bd72a87..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/delete_migration_workflow.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $migrationServiceClient->deleteMigrationWorkflow($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 = MigrationServiceClient::migrationWorkflowName( - '[PROJECT]', - '[LOCATION]', - '[WORKFLOW]' - ); - - delete_migration_workflow_sample($formattedName); -} -// [END bigquerymigration_v2_generated_MigrationService_DeleteMigrationWorkflow_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_subtask.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_subtask.php deleted file mode 100644 index 57f148e52a09..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_subtask.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var MigrationSubtask $response */ - $response = $migrationServiceClient->getMigrationSubtask($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 = MigrationServiceClient::migrationSubtaskName( - '[PROJECT]', - '[LOCATION]', - '[WORKFLOW]', - '[SUBTASK]' - ); - - get_migration_subtask_sample($formattedName); -} -// [END bigquerymigration_v2_generated_MigrationService_GetMigrationSubtask_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_workflow.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_workflow.php deleted file mode 100644 index 8e6f01903dc3..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/get_migration_workflow.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var MigrationWorkflow $response */ - $response = $migrationServiceClient->getMigrationWorkflow($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 = MigrationServiceClient::migrationWorkflowName( - '[PROJECT]', - '[LOCATION]', - '[WORKFLOW]' - ); - - get_migration_workflow_sample($formattedName); -} -// [END bigquerymigration_v2_generated_MigrationService_GetMigrationWorkflow_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_subtasks.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_subtasks.php deleted file mode 100644 index a1bfb5e200ff..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_subtasks.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $migrationServiceClient->listMigrationSubtasks($request); - - /** @var MigrationSubtask $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 = MigrationServiceClient::migrationWorkflowName( - '[PROJECT]', - '[LOCATION]', - '[WORKFLOW]' - ); - - list_migration_subtasks_sample($formattedParent); -} -// [END bigquerymigration_v2_generated_MigrationService_ListMigrationSubtasks_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_workflows.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_workflows.php deleted file mode 100644 index d717fca6b34c..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/list_migration_workflows.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $migrationServiceClient->listMigrationWorkflows($request); - - /** @var MigrationWorkflow $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 = MigrationServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_migration_workflows_sample($formattedParent); -} -// [END bigquerymigration_v2_generated_MigrationService_ListMigrationWorkflows_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/start_migration_workflow.php b/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/start_migration_workflow.php deleted file mode 100644 index 42f452a06811..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/samples/V2/MigrationServiceClient/start_migration_workflow.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $migrationServiceClient->startMigrationWorkflow($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 = MigrationServiceClient::migrationWorkflowName( - '[PROJECT]', - '[LOCATION]', - '[WORKFLOW]' - ); - - start_migration_workflow_sample($formattedName); -} -// [END bigquerymigration_v2_generated_MigrationService_StartMigrationWorkflow_sync] diff --git a/owl-bot-staging/BigQueryMigration/v2/src/V2/Gapic/MigrationServiceGapicClient.php b/owl-bot-staging/BigQueryMigration/v2/src/V2/Gapic/MigrationServiceGapicClient.php deleted file mode 100644 index 97ce55454774..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/src/V2/Gapic/MigrationServiceGapicClient.php +++ /dev/null @@ -1,691 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $migrationWorkflow = new MigrationWorkflow(); - * $response = $migrationServiceClient->createMigrationWorkflow($formattedParent, $migrationWorkflow); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * 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. - */ -class MigrationServiceGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.bigquery.migration.v2.MigrationService'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'bigquerymigration.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $locationNameTemplate; - - private static $migrationSubtaskNameTemplate; - - private static $migrationWorkflowNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/migration_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/migration_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/migration_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/migration_service_rest_client_config.php', - ], - ], - ]; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getMigrationSubtaskNameTemplate() - { - if (self::$migrationSubtaskNameTemplate == null) { - self::$migrationSubtaskNameTemplate = new PathTemplate('projects/{project}/locations/{location}/workflows/{workflow}/subtasks/{subtask}'); - } - - return self::$migrationSubtaskNameTemplate; - } - - private static function getMigrationWorkflowNameTemplate() - { - if (self::$migrationWorkflowNameTemplate == null) { - self::$migrationWorkflowNameTemplate = new PathTemplate('projects/{project}/locations/{location}/workflows/{workflow}'); - } - - return self::$migrationWorkflowNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'location' => self::getLocationNameTemplate(), - 'migrationSubtask' => self::getMigrationSubtaskNameTemplate(), - 'migrationWorkflow' => self::getMigrationWorkflowNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * migration_subtask resource. - * - * @param string $project - * @param string $location - * @param string $workflow - * @param string $subtask - * - * @return string The formatted migration_subtask resource. - */ - public static function migrationSubtaskName($project, $location, $workflow, $subtask) - { - return self::getMigrationSubtaskNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'workflow' => $workflow, - 'subtask' => $subtask, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * migration_workflow resource. - * - * @param string $project - * @param string $location - * @param string $workflow - * - * @return string The formatted migration_workflow resource. - */ - public static function migrationWorkflowName($project, $location, $workflow) - { - return self::getMigrationWorkflowNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'workflow' => $workflow, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - location: projects/{project}/locations/{location} - * - migrationSubtask: projects/{project}/locations/{location}/workflows/{workflow}/subtasks/{subtask} - * - migrationWorkflow: projects/{project}/locations/{location}/workflows/{workflow} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'bigquerymigration.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a migration workflow. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedParent = $migrationServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * $migrationWorkflow = new MigrationWorkflow(); - * $response = $migrationServiceClient->createMigrationWorkflow($formattedParent, $migrationWorkflow); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the project to which this migration workflow belongs. - * Example: `projects/foo/locations/bar` - * @param MigrationWorkflow $migrationWorkflow Required. The migration workflow to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow - * - * @throws ApiException if the remote call fails - */ - public function createMigrationWorkflow($parent, $migrationWorkflow, array $optionalArgs = []) - { - $request = new CreateMigrationWorkflowRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setMigrationWorkflow($migrationWorkflow); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateMigrationWorkflow', MigrationWorkflow::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a migration workflow by name. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedName = $migrationServiceClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - * $migrationServiceClient->deleteMigrationWorkflow($formattedName); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteMigrationWorkflow($name, array $optionalArgs = []) - { - $request = new DeleteMigrationWorkflowRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteMigrationWorkflow', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a previously created migration subtask. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedName = $migrationServiceClient->migrationSubtaskName('[PROJECT]', '[LOCATION]', '[WORKFLOW]', '[SUBTASK]'); - * $response = $migrationServiceClient->getMigrationSubtask($formattedName); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The unique identifier for the migration subtask. - * Example: `projects/123/locations/us/workflows/1234/subtasks/543` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $readMask - * Optional. The list of fields to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\Migration\V2\MigrationSubtask - * - * @throws ApiException if the remote call fails - */ - public function getMigrationSubtask($name, array $optionalArgs = []) - { - $request = new GetMigrationSubtaskRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['readMask'])) { - $request->setReadMask($optionalArgs['readMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetMigrationSubtask', MigrationSubtask::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a previously created migration workflow. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedName = $migrationServiceClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - * $response = $migrationServiceClient->getMigrationWorkflow($formattedName); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $readMask - * The list of fields to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow - * - * @throws ApiException if the remote call fails - */ - public function getMigrationWorkflow($name, array $optionalArgs = []) - { - $request = new GetMigrationWorkflowRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['readMask'])) { - $request->setReadMask($optionalArgs['readMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetMigrationWorkflow', MigrationWorkflow::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists previously created migration subtasks. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedParent = $migrationServiceClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - * // Iterate over pages of elements - * $pagedResponse = $migrationServiceClient->listMigrationSubtasks($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $migrationServiceClient->listMigrationSubtasks($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The migration task of the subtasks to list. - * Example: `projects/123/locations/us/workflows/1234` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $readMask - * Optional. The list of fields to be retrieved. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Optional. The filter to apply. This can be used to get the subtasks of a - * specific tasks in a workflow, e.g. `migration_task = "ab012"` where - * `"ab012"` is the task ID (not the name in the named map). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listMigrationSubtasks($parent, array $optionalArgs = []) - { - $request = new ListMigrationSubtasksRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['readMask'])) { - $request->setReadMask($optionalArgs['readMask']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListMigrationSubtasks', $optionalArgs, ListMigrationSubtasksResponse::class, $request); - } - - /** - * Lists previously created migration workflow. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedParent = $migrationServiceClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $migrationServiceClient->listMigrationWorkflows($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $migrationServiceClient->listMigrationWorkflows($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location of the migration workflows to list. - * Example: `projects/123/locations/us` - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $readMask - * The list of fields to be retrieved. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listMigrationWorkflows($parent, array $optionalArgs = []) - { - $request = new ListMigrationWorkflowsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['readMask'])) { - $request->setReadMask($optionalArgs['readMask']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListMigrationWorkflows', $optionalArgs, ListMigrationWorkflowsResponse::class, $request); - } - - /** - * Starts a previously created migration workflow. I.e., the state transitions - * from DRAFT to RUNNING. This is a no-op if the state is already RUNNING. - * An error will be signaled if the state is anything other than DRAFT or - * RUNNING. - * - * Sample code: - * ``` - * $migrationServiceClient = new MigrationServiceClient(); - * try { - * $formattedName = $migrationServiceClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - * $migrationServiceClient->startMigrationWorkflow($formattedName); - * } finally { - * $migrationServiceClient->close(); - * } - * ``` - * - * @param string $name Required. The unique identifier for the migration workflow. - * Example: `projects/123/locations/us/workflows/1234` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function startMigrationWorkflow($name, array $optionalArgs = []) - { - $request = new StartMigrationWorkflowRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('StartMigrationWorkflow', GPBEmpty::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/BigQueryMigration/v2/src/V2/MigrationServiceClient.php b/owl-bot-staging/BigQueryMigration/v2/src/V2/MigrationServiceClient.php deleted file mode 100644 index fb2e77e020ed..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/src/V2/MigrationServiceClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.cloud.bigquery.migration.v2.MigrationService' => [ - 'CreateMigrationWorkflow' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteMigrationWorkflow' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetMigrationSubtask' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationSubtask', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetMigrationWorkflow' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\MigrationWorkflow', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListMigrationSubtasks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getMigrationSubtasks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\ListMigrationSubtasksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListMigrationWorkflows' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getMigrationWorkflows', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\BigQuery\Migration\V2\ListMigrationWorkflowsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'StartMigrationWorkflow' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'location' => 'projects/{project}/locations/{location}', - 'migrationSubtask' => 'projects/{project}/locations/{location}/workflows/{workflow}/subtasks/{subtask}', - 'migrationWorkflow' => 'projects/{project}/locations/{location}/workflows/{workflow}', - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_rest_client_config.php b/owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_rest_client_config.php deleted file mode 100644 index b93e6bb69ad6..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/src/V2/resources/migration_service_rest_client_config.php +++ /dev/null @@ -1,87 +0,0 @@ - [ - 'google.cloud.bigquery.migration.v2.MigrationService' => [ - 'CreateMigrationWorkflow' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/workflows', - 'body' => 'migration_workflow', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteMigrationWorkflow' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/workflows/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetMigrationSubtask' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/workflows/*/subtasks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetMigrationWorkflow' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/workflows/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListMigrationSubtasks' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*/workflows/*}/subtasks', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListMigrationWorkflows' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/workflows', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'StartMigrationWorkflow' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/workflows/*}:start', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/MigrationServiceClientTest.php b/owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/MigrationServiceClientTest.php deleted file mode 100644 index ed7f357bea30..000000000000 --- a/owl-bot-staging/BigQueryMigration/v2/tests/Unit/V2/MigrationServiceClientTest.php +++ /dev/null @@ -1,509 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return MigrationServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new MigrationServiceClient($options); - } - - /** @test */ - public function createMigrationWorkflowTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new MigrationWorkflow(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $migrationWorkflow = new MigrationWorkflow(); - $response = $gapicClient->createMigrationWorkflow($formattedParent, $migrationWorkflow); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/CreateMigrationWorkflow', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getMigrationWorkflow(); - $this->assertProtobufEquals($migrationWorkflow, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMigrationWorkflowExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $migrationWorkflow = new MigrationWorkflow(); - try { - $gapicClient->createMigrationWorkflow($formattedParent, $migrationWorkflow); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMigrationWorkflowTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - $gapicClient->deleteMigrationWorkflow($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/DeleteMigrationWorkflow', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMigrationWorkflowExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - try { - $gapicClient->deleteMigrationWorkflow($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMigrationSubtaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $taskId = 'taskId-1537240555'; - $type = 'type3575610'; - $resourceErrorCount = 929997465; - $expectedResponse = new MigrationSubtask(); - $expectedResponse->setName($name2); - $expectedResponse->setTaskId($taskId); - $expectedResponse->setType($type); - $expectedResponse->setResourceErrorCount($resourceErrorCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->migrationSubtaskName('[PROJECT]', '[LOCATION]', '[WORKFLOW]', '[SUBTASK]'); - $response = $gapicClient->getMigrationSubtask($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/GetMigrationSubtask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMigrationSubtaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->migrationSubtaskName('[PROJECT]', '[LOCATION]', '[WORKFLOW]', '[SUBTASK]'); - try { - $gapicClient->getMigrationSubtask($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMigrationWorkflowTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new MigrationWorkflow(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - $response = $gapicClient->getMigrationWorkflow($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/GetMigrationWorkflow', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMigrationWorkflowExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - try { - $gapicClient->getMigrationWorkflow($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMigrationSubtasksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $migrationSubtasksElement = new MigrationSubtask(); - $migrationSubtasks = [ - $migrationSubtasksElement, - ]; - $expectedResponse = new ListMigrationSubtasksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMigrationSubtasks($migrationSubtasks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - $response = $gapicClient->listMigrationSubtasks($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMigrationSubtasks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/ListMigrationSubtasks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMigrationSubtasksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - try { - $gapicClient->listMigrationSubtasks($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMigrationWorkflowsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $migrationWorkflowsElement = new MigrationWorkflow(); - $migrationWorkflows = [ - $migrationWorkflowsElement, - ]; - $expectedResponse = new ListMigrationWorkflowsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMigrationWorkflows($migrationWorkflows); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listMigrationWorkflows($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMigrationWorkflows()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/ListMigrationWorkflows', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMigrationWorkflowsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listMigrationWorkflows($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function startMigrationWorkflowTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - $gapicClient->startMigrationWorkflow($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.bigquery.migration.v2.MigrationService/StartMigrationWorkflow', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function startMigrationWorkflowExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->migrationWorkflowName('[PROJECT]', '[LOCATION]', '[WORKFLOW]'); - try { - $gapicClient->startMigrationWorkflow($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/Build/v1/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V1/Cloudbuild.php b/owl-bot-staging/Build/v1/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V1/Cloudbuild.php deleted file mode 100644 index a4f751ba59999f95908a22f768f70d8e24fa0472..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23141 zcmdU1TWlNIc@8P-cBq@jH(FWm(qr$&tJP95z4mVCy$vZ!;#v|_lCoo02uqP8X<~|G zI72zk#z<4NP5Ra=iUw&Kr1u7Bfuc=Ov=2p#qQC+LiWcaD(E>|Yoc}-P{O3Ra;@ImL->+w994Z_SKt= zRcdA1j&)ku`z(h4n(f`1Rf*Y7*}*@TExTmZEypU?tS?|qZ^ib?HQNMvZ{NLkz2aDn zdW;Bi^@@4r<(S|}eJ?k$7SOACZIM_YlAUbbF6&HMo#AL!EVEWknFr+~tI-;cbj@*^yN&9@;i&SaRJVbbw%(}kx7zi( zRo~yqHA%^b6OFs$%WXkB_=H_jY*ps4=?t+}my}C*qio-QhGB~qPMA|ZZ1$(+y8Y_g zmegdUT6Gn71xNjgt7@cppJ3nnc8JA?JLK90(Lb(?LcC)X;zw8K&q;RWrUe5*>L-lD z{0p83d!%EfU8!WU!+B4K1F1=U9<`*p$VZnXRjs2FOAS{iWT)q4r=~pWOI5k?^7+TR zpPRI`@}aVVF0q*XAvRFJM& zCR3N67#GWnnag-3I+{LhNk5 zUFT%QmbJfcw$#9%k^`UMyJ zSv$ibyRCA)av&P{-mZNN)Dup5U$k+tqwO?2U*qu5a!U3=Sxf`1a#rJfR;SsNRX;LY zPN`+?o1c$PpmjnkuxY!!YdeA)Tybb-L?Gm#f#fc=Y1kA!!KG5G`=lm-v9ZDJTosA@3 z3t;A3l9KP*$5IpOkm-kv(UEtuhd4IclsxI&P|!Y9t$pl>FgcpRBF(maP=d9BCykO` zMiM)p2$%zTphB};Pr>et=)WIgXSSQQM!9NMw;nnNjrvx(a-YWLXU&qT^EQj@!T*#F z%JzY2%MA=N1>~{TI6?PR#om2{scw{y%(~HXti5u@`O%x|?}V79q`KKW{E-#uS5B}= z?qLd!+3eCb?7vw*!d8#Kyh0Jnt$iDcM}J8h#|HFXtF#8sRM8#YF{M%#`~q3cZI71gzWG#2NZ6EAQQeqiCC zrpvWj<3VY!Y}MK=GdcrC6WUoeX?`A(uQaM=bPi3UqI;ChiSF)GJE}qAqhw7)mJ~gO z?vwguHYR22w>tQ%S#}PD)6oBQgpDKMZ`T}~LIaD;6xjoEU_ti4W7y8Kle-j4m24

RmTv+dYi|E3`DS=C)_GAZE@c2e75 zvrTRpOUR7LG}>HegRQ-?0Dij)c86rWJj)RNKgf9~c7EHp%BJeg!_L&E_*PsE&@08O zW1RG#Vl&F1iVdcis@ACRpjuX(osj*S6&^ao={W~0J{Kqie9(S|7b4y;Wxx|itVhMu8iA7pqM$d50OG?DY*lnQ| zTP~T9`vo>943#I0(NPj`eo(`=&L zq`fKEqKjN&K{*9qmmz5clXuvxZMKfAidiaGDvdV6lm#xom!24x*hQ;+C@1Hp@&(b| z5WNvYoGc%~ij;Q|AS-b!@#zGe?^i_3eD7RJ^;D>6-g2i)?Kd)=Ja`iwW^%QbTsbSk07x*q2sv+ndW+&pCFAccnIC zySN5X+ylu7EYs|IZgmx_=4>$1+zD#jE@bkh)OL1#xl|}-w&q5O#Y(1_UMm%H+xc`x zjXL&h(7^m{7V#W7iupT8!VNEyFhndxn1lWsAwUD%{USS}D~O-!#@snS4H% zhiK5DnBB6MSV`z`_(F=gX}q2q~+~2Prkj9w`XlZ#CLTlByixnFLfk z4oHzBojmKFPq1mfnf|Num2w zV^73$6K1_Cf=)80PwlO5u(RAYyB9?2K2p2JM)@h@7Cw@=9H0@Li~e^bY_2;hLuz*p z!FQu}WKt%|p=yN=icJr4!#+SyTVyc7Iny%QkEZt2B4sa+=~o8Q@Cvt18hVm-d&4ZrUQ0u4I6xbs+Mtka_1 z@aCgrA|r`Q0jnTDQvYg*ouD6D(ibZP?KY9b>3`h!`{48`{W_a)A0cSj%xz}i&EUWa zYewSw4S4@?HnOpN9nM}fUcZ`{JE8wF0xcB=z6YdS0As+F0W`Fr;k2eiz?uX-c9&?x zAKFbMQ}vovC$yh<1mzN0-dPaqe;;B~-Ub-Msr!d^2@!y}0}*+;h>-c!6Q0URx?yq} zsGrlgWj@r_*f@|rsBTkECMf;zjvdd`k2cCpam(>4i+KL@E0%vhxVBjAR6p5d*p#%O z-qkEUF&5c^%{M^Gzk5l7*==EcX>SfEmWhmq<7@m5Q+xJ1Oq^_CmxXa3$Sza1 z5!M@QcGYxzb5pmgotXv4WrN?YA_hIVZrNf;yH_4$T*aO4N00}u7n?YdB^w1VTuVmD z(efszao-d-oRgGe?BT`-r=6|`C-n-`yi>EAC>t>~>=hTTEp5U;(nU@%TSw{!4~}_= zL4~@upb&&-)P9IUZ?aP&^)`KjDlpK+{=(V{P+OU#4*F45a;xv&b?JhAi}xW!P+96~OI1Onm24K`6VE8?1; zEW=E2x*~@W^NKG^YMMrvFf+QsCkx0!X=)82(;Zqn`wpG^gN22W2odQg#9H28CLl0MuY(xG6tq??%OySkQd}Zpqi$yBUC_ zjxF^i#imgKh(ZV4N%4bn0h0}mL$)}L zPrAh0?gnecWy0G5M$fBP{V-donzdhV;JlV->UMONE6Q0mW7R9QHg5i9`y6jS<@%%N zF)NNuhqOK@=|%o@K$P^^K&a%mLLVC62n}4`^kN^>MIHu#F7nqSE!n4=LS%g4OfT)i zglbES%U`KEHnYnwGu3(1{|)h0pCj>cHfz=4erh zx+3+%6~dV=*uG>Q(p?^hO;Q7@CGLl1JRrPDke&0cT7(0-9pHh-SU7h}V84a!R3V+u zZWYOQEN9j;%7aSxC$Wj-xoYixBfpG|ESbNNCk zx4C|IE}WWVrD+5&4_Vi03C!+c%2*%-t?bCg{;aNyXLGaWIHn+*o7RMLmpQltN(h4 zMcsr=PQ*=XqOsx(^7T{!1~;$SuRf`^S< z!3B1v`Vc{tRVjG~v7;x+B5FXcPg4bj?EopGN&_`I#q%?Xp+;YC>=zUpIr=#kdC+Lx zM?OsNFNsn}9{6Pukx>g3odjRM`2{?-g>6zb z886}#u>~*K6va87g3TFpiX?(cKV)%XlRZ~8_sW2DN|>suxN+Yl;q^5$iOe7=kJ{>G z!4K27Q~dP;_4X4N%6tay(v_3;y0@e{_3{(rC3gAvmnZJ<9V2o*&Zd0lVUA7FW&Q0; zUX>~!|9Afi=?5(0)pyha_zN3|{%UD0ySkR%+Ah6;2oZ6hr{!7#p&>eD5}r<@)XCF= zPGh)v@Rj~ceVbuyW4ll+Z5XHtKrDg@80+h~JEiqpu8^4v>8rpQd)1U*$>%f12Ewux zV|%>_Qrwsqio7kiiFtyv`g3JvF06l%MZBtmIs{d*;9oJWJ=Qa;M*1#zKvt`172E(* znFDy0zO|gsLV_aX8JQ1HgizP2rPp)Y%b2w&g5crMD3yiq8QLPi(7(ld(~j+g3+*q#Rw z`U~vBG1CyfUH|GBV;$9X%Pl>yk}$tOhvbEh7@3eSb@NPzX9Q&ek#gtlMdY1y)RSr{ z$5g*{hK_q)eauiD_%mW9Kv>$`kq=ep2&yWNM20GKOsgD-;GLPo(%_5bNUV@sk)1`A z)Dc1tZthD*R~3RK${>R>D^x}iFW1DH;wZ5;LPnr8d0oD!;uc>#p#KC$98}7v88e_C)d*fYsoH3}j6;V^9c2_)L-m zkQwm@m*}Gf=}!5h1ncz6heGs14KhK%^ZH+(KxI|0FtyukT5=N|lSUCBtRvT1W4AhxXnB^qlcvGGw? z8qaX9(vMwc=ll~bS)k&_t2%j)^U#S4B`6Yf=7FYSe2FIchke=hOn`n z6i6_*k{%Bc{6mOc>^@YzWnOsa&@;X=PXh<+fRrN@&$|)gjP-60m9qhpKWu7O*)&-^ zf-XeBAd>v2km$6MZXNsaT}k%|{;^z1;yafZOVcMxc&e=ZA4;}8=%y9~@q7A8%Q$~Q zc{I;Q3gWJCP|*A{|MI`Vr~hfoR=2#UX?P}vi~!!U6_HgwiLW{w}65i+P%0Y zmj5&}pw37aw5f z)%qVBo^Q{PiPw5B$O4tUmqe}ktWtJJn12Z^&cAG>%e`F~es33kFnjxlVfqY4_x)So zN_$DvN{2eu-xkOEXG4i$1<*O@I_m%7&7rm%$C$p-|#be__U;ST{oweT$ zv)QiiJp~$ouKr3&0gmyngj^i`+K^{HiEp+g<=3DF@{(Rb5N&ATvGH7gF^D_R0bIqe zh1r?D;J0>D9fM<{+rCsvX2Bm{>I?fz+ws#vq+ifq8$zUyk`F|gVv=7I+wf)?~HUpIl0Mt}x=O)U3qogb_q4=9p&4$~&R8U179qOhNfo;2V4 z8}8u)W65`uF#v4vCn$~b;aghJD}%n?N(6)B9Qxbbb6gcZ^r_qD5e4^&9B|YAGsNb) zQ}4j7>n2e14%oW)#ax9?7=ErF7)f?UeA!NX8V}#y6y8R=*gYdRL3Ur<`zmy_8!ZW3 zXg9%t3;nv#(f1NJxdHd6So~=R%)dij`g+d8Ww9;pqX_!z(bDcY_ln|g5${nfa)%>q z{BQ)C`>y^<5J88$hfEr+cYSIb5XyMu^4O5D_x#2O#`$CK&i~nn(^nwvC_*E=U4f6Y~vgo694CEK>YUA55i}}!yWN)+npW$WC!23{V*IA zkCI7Fm`w6V$s`^bn}K&Ei_+cU@=E@Cw6tGq?3Qaw^4 z`ArJ&>?)20@AudxQN{7pm)o>UeYsbV=W?#}1I(&Jy(!o4ZFn)44$mc&E742MXpz4# zOp{&YyZ+SI3vczAaVJ;xylaow7xTC_zzF!&!mme574?#$XvC1)gVihd8Pi(=P3!X1 zH-qoHPp@b0_e}v_5e-iK-$%P+7}IH7`-J-u*hTSmV$a8n0c7K2%Y8m%%zKIt4nJa# G82f*F+Euv# diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalConfig.php deleted file mode 100644 index 6daec89cd040..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalConfig.php +++ /dev/null @@ -1,75 +0,0 @@ -google.devtools.cloudbuild.v1.ApprovalConfig - */ -class ApprovalConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Whether or not approval is needed. If this is set on a build, it will - * become pending when created, and will need to be explicitly approved - * to start. - * - * Generated from protobuf field bool approval_required = 1; - */ - protected $approval_required = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $approval_required - * Whether or not approval is needed. If this is set on a build, it will - * become pending when created, and will need to be explicitly approved - * to start. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Whether or not approval is needed. If this is set on a build, it will - * become pending when created, and will need to be explicitly approved - * to start. - * - * Generated from protobuf field bool approval_required = 1; - * @return bool - */ - public function getApprovalRequired() - { - return $this->approval_required; - } - - /** - * Whether or not approval is needed. If this is set on a build, it will - * become pending when created, and will need to be explicitly approved - * to start. - * - * Generated from protobuf field bool approval_required = 1; - * @param bool $var - * @return $this - */ - public function setApprovalRequired($var) - { - GPBUtil::checkBool($var); - $this->approval_required = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult.php deleted file mode 100644 index 8124b5be5a9a..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult.php +++ /dev/null @@ -1,230 +0,0 @@ -google.devtools.cloudbuild.v1.ApprovalResult - */ -class ApprovalResult extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Email of the user that called the ApproveBuild API to - * approve or reject a build at the time that the API was called. - * - * Generated from protobuf field string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $approver_account = ''; - /** - * Output only. The time when the approval decision was made. - * - * Generated from protobuf field .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $approval_time = null; - /** - * Required. The decision of this manual approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $decision = 0; - /** - * Optional. An optional comment for this manual approval result. - * - * Generated from protobuf field string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $comment = ''; - /** - * Optional. An optional URL tied to this manual approval result. This field - * is essentially the same as comment, except that it will be rendered by the - * UI differently. An example use case is a link to an external job that - * approved this Build. - * - * Generated from protobuf field string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $url = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $approver_account - * Output only. Email of the user that called the ApproveBuild API to - * approve or reject a build at the time that the API was called. - * @type \Google\Protobuf\Timestamp $approval_time - * Output only. The time when the approval decision was made. - * @type int $decision - * Required. The decision of this manual approval. - * @type string $comment - * Optional. An optional comment for this manual approval result. - * @type string $url - * Optional. An optional URL tied to this manual approval result. This field - * is essentially the same as comment, except that it will be rendered by the - * UI differently. An example use case is a link to an external job that - * approved this Build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Email of the user that called the ApproveBuild API to - * approve or reject a build at the time that the API was called. - * - * Generated from protobuf field string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApproverAccount() - { - return $this->approver_account; - } - - /** - * Output only. Email of the user that called the ApproveBuild API to - * approve or reject a build at the time that the API was called. - * - * Generated from protobuf field string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApproverAccount($var) - { - GPBUtil::checkString($var, True); - $this->approver_account = $var; - - return $this; - } - - /** - * Output only. The time when the approval decision was made. - * - * Generated from protobuf field .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getApprovalTime() - { - return $this->approval_time; - } - - public function hasApprovalTime() - { - return isset($this->approval_time); - } - - public function clearApprovalTime() - { - unset($this->approval_time); - } - - /** - * Output only. The time when the approval decision was made. - * - * Generated from protobuf field .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setApprovalTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->approval_time = $var; - - return $this; - } - - /** - * Required. The decision of this manual approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getDecision() - { - return $this->decision; - } - - /** - * Required. The decision of this manual approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setDecision($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\ApprovalResult\Decision::class); - $this->decision = $var; - - return $this; - } - - /** - * Optional. An optional comment for this manual approval result. - * - * Generated from protobuf field string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getComment() - { - return $this->comment; - } - - /** - * Optional. An optional comment for this manual approval result. - * - * Generated from protobuf field string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setComment($var) - { - GPBUtil::checkString($var, True); - $this->comment = $var; - - return $this; - } - - /** - * Optional. An optional URL tied to this manual approval result. This field - * is essentially the same as comment, except that it will be rendered by the - * UI differently. An example use case is a link to an external job that - * approved this Build. - * - * Generated from protobuf field string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * Optional. An optional URL tied to this manual approval result. This field - * is essentially the same as comment, except that it will be rendered by the - * UI differently. An example use case is a link to an external job that - * approved this Build. - * - * Generated from protobuf field string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult/Decision.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult/Decision.php deleted file mode 100644 index 3ee8714acb5e..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult/Decision.php +++ /dev/null @@ -1,65 +0,0 @@ -google.devtools.cloudbuild.v1.ApprovalResult.Decision - */ -class Decision -{ - /** - * Default enum type. This should not be used. - * - * Generated from protobuf enum DECISION_UNSPECIFIED = 0; - */ - const DECISION_UNSPECIFIED = 0; - /** - * Build is approved. - * - * Generated from protobuf enum APPROVED = 1; - */ - const APPROVED = 1; - /** - * Build is rejected. - * - * Generated from protobuf enum REJECTED = 2; - */ - const REJECTED = 2; - - private static $valueToName = [ - self::DECISION_UNSPECIFIED => 'DECISION_UNSPECIFIED', - self::APPROVED => 'APPROVED', - self::REJECTED => 'REJECTED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Decision::class, \Google\Cloud\Build\V1\ApprovalResult_Decision::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult_Decision.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult_Decision.php deleted file mode 100644 index cd4cc4aefb14..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ApprovalResult_Decision.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.ApproveBuildRequest - */ -class ApproveBuildRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the target build. - * For example: "projects/{$project_id}/builds/{$build_id}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Approval decision and metadata. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - protected $approval_result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the target build. - * For example: "projects/{$project_id}/builds/{$build_id}" - * @type \Google\Cloud\Build\V1\ApprovalResult $approval_result - * Approval decision and metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the target build. - * For example: "projects/{$project_id}/builds/{$build_id}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the target build. - * For example: "projects/{$project_id}/builds/{$build_id}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Approval decision and metadata. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * @return \Google\Cloud\Build\V1\ApprovalResult|null - */ - public function getApprovalResult() - { - return $this->approval_result; - } - - public function hasApprovalResult() - { - return isset($this->approval_result); - } - - public function clearApprovalResult() - { - unset($this->approval_result); - } - - /** - * Approval decision and metadata. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * @param \Google\Cloud\Build\V1\ApprovalResult $var - * @return $this - */ - public function setApprovalResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\ApprovalResult::class); - $this->approval_result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ArtifactResult.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ArtifactResult.php deleted file mode 100644 index e65e6b647924..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ArtifactResult.php +++ /dev/null @@ -1,110 +0,0 @@ -google.devtools.cloudbuild.v1.ArtifactResult - */ -class ArtifactResult extends \Google\Protobuf\Internal\Message -{ - /** - * The path of an artifact in a Google Cloud Storage bucket, with the - * generation number. For example, - * `gs://mybucket/path/to/output.jar#generation`. - * - * Generated from protobuf field string location = 1; - */ - protected $location = ''; - /** - * The file hash of the artifact. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - private $file_hash; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $location - * The path of an artifact in a Google Cloud Storage bucket, with the - * generation number. For example, - * `gs://mybucket/path/to/output.jar#generation`. - * @type array<\Google\Cloud\Build\V1\FileHashes>|\Google\Protobuf\Internal\RepeatedField $file_hash - * The file hash of the artifact. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The path of an artifact in a Google Cloud Storage bucket, with the - * generation number. For example, - * `gs://mybucket/path/to/output.jar#generation`. - * - * Generated from protobuf field string location = 1; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * The path of an artifact in a Google Cloud Storage bucket, with the - * generation number. For example, - * `gs://mybucket/path/to/output.jar#generation`. - * - * Generated from protobuf field string location = 1; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - - /** - * The file hash of the artifact. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileHash() - { - return $this->file_hash; - } - - /** - * The file hash of the artifact. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - * @param array<\Google\Cloud\Build\V1\FileHashes>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileHash($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\FileHashes::class); - $this->file_hash = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts.php deleted file mode 100644 index 113f31545abe..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts.php +++ /dev/null @@ -1,314 +0,0 @@ -google.devtools.cloudbuild.v1.Artifacts - */ -class Artifacts extends \Google\Protobuf\Internal\Message -{ - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images will be pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the Build resource's - * results field. - * If any of the images fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated string images = 1; - */ - private $images; - /** - * A list of objects to be uploaded to Cloud Storage upon successful - * completion of all build steps. - * Files in the workspace matching specified paths globs will be uploaded to - * the specified Cloud Storage location using the builder service account's - * credentials. - * The location and generation of the uploaded objects will be stored in the - * Build resource's results field. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - protected $objects = null; - /** - * A list of Maven artifacts to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Artifacts in the workspace matching specified paths globs will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any artifacts fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.MavenArtifact maven_artifacts = 3; - */ - private $maven_artifacts; - /** - * A list of Python packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * The build service account credentials will be used to perform the upload. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.PythonPackage python_packages = 5; - */ - private $python_packages; - /** - * A list of npm packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Npm packages in the specified paths will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any packages fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.NpmPackage npm_packages = 6; - */ - private $npm_packages; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $images - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images will be pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the Build resource's - * results field. - * If any of the images fail to be pushed, the build is marked FAILURE. - * @type \Google\Cloud\Build\V1\Artifacts\ArtifactObjects $objects - * A list of objects to be uploaded to Cloud Storage upon successful - * completion of all build steps. - * Files in the workspace matching specified paths globs will be uploaded to - * the specified Cloud Storage location using the builder service account's - * credentials. - * The location and generation of the uploaded objects will be stored in the - * Build resource's results field. - * If any objects fail to be pushed, the build is marked FAILURE. - * @type array<\Google\Cloud\Build\V1\Artifacts\MavenArtifact>|\Google\Protobuf\Internal\RepeatedField $maven_artifacts - * A list of Maven artifacts to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Artifacts in the workspace matching specified paths globs will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any artifacts fail to be pushed, the build is marked FAILURE. - * @type array<\Google\Cloud\Build\V1\Artifacts\PythonPackage>|\Google\Protobuf\Internal\RepeatedField $python_packages - * A list of Python packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * The build service account credentials will be used to perform the upload. - * If any objects fail to be pushed, the build is marked FAILURE. - * @type array<\Google\Cloud\Build\V1\Artifacts\NpmPackage>|\Google\Protobuf\Internal\RepeatedField $npm_packages - * A list of npm packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Npm packages in the specified paths will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any packages fail to be pushed, the build is marked FAILURE. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images will be pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the Build resource's - * results field. - * If any of the images fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated string images = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getImages() - { - return $this->images; - } - - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images will be pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the Build resource's - * results field. - * If any of the images fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated string images = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setImages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->images = $arr; - - return $this; - } - - /** - * A list of objects to be uploaded to Cloud Storage upon successful - * completion of all build steps. - * Files in the workspace matching specified paths globs will be uploaded to - * the specified Cloud Storage location using the builder service account's - * credentials. - * The location and generation of the uploaded objects will be stored in the - * Build resource's results field. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * @return \Google\Cloud\Build\V1\Artifacts\ArtifactObjects|null - */ - public function getObjects() - { - return $this->objects; - } - - public function hasObjects() - { - return isset($this->objects); - } - - public function clearObjects() - { - unset($this->objects); - } - - /** - * A list of objects to be uploaded to Cloud Storage upon successful - * completion of all build steps. - * Files in the workspace matching specified paths globs will be uploaded to - * the specified Cloud Storage location using the builder service account's - * credentials. - * The location and generation of the uploaded objects will be stored in the - * Build resource's results field. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * @param \Google\Cloud\Build\V1\Artifacts\ArtifactObjects $var - * @return $this - */ - public function setObjects($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Artifacts\ArtifactObjects::class); - $this->objects = $var; - - return $this; - } - - /** - * A list of Maven artifacts to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Artifacts in the workspace matching specified paths globs will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any artifacts fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.MavenArtifact maven_artifacts = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMavenArtifacts() - { - return $this->maven_artifacts; - } - - /** - * A list of Maven artifacts to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Artifacts in the workspace matching specified paths globs will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any artifacts fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.MavenArtifact maven_artifacts = 3; - * @param array<\Google\Cloud\Build\V1\Artifacts\MavenArtifact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMavenArtifacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Artifacts\MavenArtifact::class); - $this->maven_artifacts = $arr; - - return $this; - } - - /** - * A list of Python packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * The build service account credentials will be used to perform the upload. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.PythonPackage python_packages = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPythonPackages() - { - return $this->python_packages; - } - - /** - * A list of Python packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * The build service account credentials will be used to perform the upload. - * If any objects fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.PythonPackage python_packages = 5; - * @param array<\Google\Cloud\Build\V1\Artifacts\PythonPackage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPythonPackages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Artifacts\PythonPackage::class); - $this->python_packages = $arr; - - return $this; - } - - /** - * A list of npm packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Npm packages in the specified paths will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any packages fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.NpmPackage npm_packages = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNpmPackages() - { - return $this->npm_packages; - } - - /** - * A list of npm packages to be uploaded to Artifact Registry upon - * successful completion of all build steps. - * Npm packages in the specified paths will be uploaded - * to the specified Artifact Registry repository using the builder service - * account's credentials. - * If any packages fail to be pushed, the build is marked FAILURE. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Artifacts.NpmPackage npm_packages = 6; - * @param array<\Google\Cloud\Build\V1\Artifacts\NpmPackage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNpmPackages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Artifacts\NpmPackage::class); - $this->npm_packages = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/ArtifactObjects.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/ArtifactObjects.php deleted file mode 100644 index 66ab42606c97..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/ArtifactObjects.php +++ /dev/null @@ -1,165 +0,0 @@ -google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects - */ -class ArtifactObjects extends \Google\Protobuf\Internal\Message -{ - /** - * Cloud Storage bucket and optional object path, in the form - * "gs://bucket/path/to/somewhere/". (see [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Files in the workspace matching any path pattern will be uploaded to - * Cloud Storage with this location as a prefix. - * - * Generated from protobuf field string location = 1; - */ - protected $location = ''; - /** - * Path globs used to match files in the build's workspace. - * - * Generated from protobuf field repeated string paths = 2; - */ - private $paths; - /** - * Output only. Stores timing information for pushing all artifact objects. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $timing = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $location - * Cloud Storage bucket and optional object path, in the form - * "gs://bucket/path/to/somewhere/". (see [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Files in the workspace matching any path pattern will be uploaded to - * Cloud Storage with this location as a prefix. - * @type array|\Google\Protobuf\Internal\RepeatedField $paths - * Path globs used to match files in the build's workspace. - * @type \Google\Cloud\Build\V1\TimeSpan $timing - * Output only. Stores timing information for pushing all artifact objects. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Cloud Storage bucket and optional object path, in the form - * "gs://bucket/path/to/somewhere/". (see [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Files in the workspace matching any path pattern will be uploaded to - * Cloud Storage with this location as a prefix. - * - * Generated from protobuf field string location = 1; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * Cloud Storage bucket and optional object path, in the form - * "gs://bucket/path/to/somewhere/". (see [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Files in the workspace matching any path pattern will be uploaded to - * Cloud Storage with this location as a prefix. - * - * Generated from protobuf field string location = 1; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - - /** - * Path globs used to match files in the build's workspace. - * - * Generated from protobuf field repeated string paths = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPaths() - { - return $this->paths; - } - - /** - * Path globs used to match files in the build's workspace. - * - * Generated from protobuf field repeated string paths = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPaths($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->paths = $arr; - - return $this; - } - - /** - * Output only. Stores timing information for pushing all artifact objects. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getTiming() - { - return $this->timing; - } - - public function hasTiming() - { - return isset($this->timing); - } - - public function clearTiming() - { - unset($this->timing); - } - - /** - * Output only. Stores timing information for pushing all artifact objects. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->timing = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ArtifactObjects::class, \Google\Cloud\Build\V1\Artifacts_ArtifactObjects::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/MavenArtifact.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/MavenArtifact.php deleted file mode 100644 index 09ecc8322e95..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/MavenArtifact.php +++ /dev/null @@ -1,251 +0,0 @@ -google.devtools.cloudbuild.v1.Artifacts.MavenArtifact - */ -class MavenArtifact extends \Google\Protobuf\Internal\Message -{ - /** - * Artifact Registry repository, in the form - * "https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY" - * Artifact in the workspace specified by path will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - */ - protected $repository = ''; - /** - * Path to an artifact in the build's workspace to be uploaded to - * Artifact Registry. - * This can be either an absolute path, - * e.g. /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar - * or a relative path from /workspace, - * e.g. my-app/target/my-app-1.0.SNAPSHOT.jar. - * - * Generated from protobuf field string path = 2; - */ - protected $path = ''; - /** - * Maven `artifactId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string artifact_id = 3; - */ - protected $artifact_id = ''; - /** - * Maven `groupId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string group_id = 4; - */ - protected $group_id = ''; - /** - * Maven `version` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string version = 5; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $repository - * Artifact Registry repository, in the form - * "https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY" - * Artifact in the workspace specified by path will be uploaded to - * Artifact Registry with this location as a prefix. - * @type string $path - * Path to an artifact in the build's workspace to be uploaded to - * Artifact Registry. - * This can be either an absolute path, - * e.g. /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar - * or a relative path from /workspace, - * e.g. my-app/target/my-app-1.0.SNAPSHOT.jar. - * @type string $artifact_id - * Maven `artifactId` value used when uploading the artifact to Artifact - * Registry. - * @type string $group_id - * Maven `groupId` value used when uploading the artifact to Artifact - * Registry. - * @type string $version - * Maven `version` value used when uploading the artifact to Artifact - * Registry. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY" - * Artifact in the workspace specified by path will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @return string - */ - public function getRepository() - { - return $this->repository; - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY" - * Artifact in the workspace specified by path will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @param string $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkString($var, True); - $this->repository = $var; - - return $this; - } - - /** - * Path to an artifact in the build's workspace to be uploaded to - * Artifact Registry. - * This can be either an absolute path, - * e.g. /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar - * or a relative path from /workspace, - * e.g. my-app/target/my-app-1.0.SNAPSHOT.jar. - * - * Generated from protobuf field string path = 2; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * Path to an artifact in the build's workspace to be uploaded to - * Artifact Registry. - * This can be either an absolute path, - * e.g. /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar - * or a relative path from /workspace, - * e.g. my-app/target/my-app-1.0.SNAPSHOT.jar. - * - * Generated from protobuf field string path = 2; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - - /** - * Maven `artifactId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string artifact_id = 3; - * @return string - */ - public function getArtifactId() - { - return $this->artifact_id; - } - - /** - * Maven `artifactId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string artifact_id = 3; - * @param string $var - * @return $this - */ - public function setArtifactId($var) - { - GPBUtil::checkString($var, True); - $this->artifact_id = $var; - - return $this; - } - - /** - * Maven `groupId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string group_id = 4; - * @return string - */ - public function getGroupId() - { - return $this->group_id; - } - - /** - * Maven `groupId` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string group_id = 4; - * @param string $var - * @return $this - */ - public function setGroupId($var) - { - GPBUtil::checkString($var, True); - $this->group_id = $var; - - return $this; - } - - /** - * Maven `version` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string version = 5; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Maven `version` value used when uploading the artifact to Artifact - * Registry. - * - * Generated from protobuf field string version = 5; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MavenArtifact::class, \Google\Cloud\Build\V1\Artifacts_MavenArtifact::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/NpmPackage.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/NpmPackage.php deleted file mode 100644 index a00ac39f289f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/NpmPackage.php +++ /dev/null @@ -1,121 +0,0 @@ -google.devtools.cloudbuild.v1.Artifacts.NpmPackage - */ -class NpmPackage extends \Google\Protobuf\Internal\Message -{ - /** - * Artifact Registry repository, in the form - * "https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY" - * Npm package in the workspace specified by path will be zipped and - * uploaded to Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - */ - protected $repository = ''; - /** - * Path to the package.json. - * e.g. workspace/path/to/package - * - * Generated from protobuf field string package_path = 2; - */ - protected $package_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $repository - * Artifact Registry repository, in the form - * "https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY" - * Npm package in the workspace specified by path will be zipped and - * uploaded to Artifact Registry with this location as a prefix. - * @type string $package_path - * Path to the package.json. - * e.g. workspace/path/to/package - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY" - * Npm package in the workspace specified by path will be zipped and - * uploaded to Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @return string - */ - public function getRepository() - { - return $this->repository; - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY" - * Npm package in the workspace specified by path will be zipped and - * uploaded to Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @param string $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkString($var, True); - $this->repository = $var; - - return $this; - } - - /** - * Path to the package.json. - * e.g. workspace/path/to/package - * - * Generated from protobuf field string package_path = 2; - * @return string - */ - public function getPackagePath() - { - return $this->package_path; - } - - /** - * Path to the package.json. - * e.g. workspace/path/to/package - * - * Generated from protobuf field string package_path = 2; - * @param string $var - * @return $this - */ - public function setPackagePath($var) - { - GPBUtil::checkString($var, True); - $this->package_path = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NpmPackage::class, \Google\Cloud\Build\V1\Artifacts_NpmPackage::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/PythonPackage.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/PythonPackage.php deleted file mode 100644 index 652136c673cd..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts/PythonPackage.php +++ /dev/null @@ -1,126 +0,0 @@ -google.devtools.cloudbuild.v1.Artifacts.PythonPackage - */ -class PythonPackage extends \Google\Protobuf\Internal\Message -{ - /** - * Artifact Registry repository, in the form - * "https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY" - * Files in the workspace matching any path pattern will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - */ - protected $repository = ''; - /** - * Path globs used to match files in the build's workspace. For Python/ - * Twine, this is usually `dist/*`, and sometimes additionally an `.asc` - * file. - * - * Generated from protobuf field repeated string paths = 2; - */ - private $paths; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $repository - * Artifact Registry repository, in the form - * "https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY" - * Files in the workspace matching any path pattern will be uploaded to - * Artifact Registry with this location as a prefix. - * @type array|\Google\Protobuf\Internal\RepeatedField $paths - * Path globs used to match files in the build's workspace. For Python/ - * Twine, this is usually `dist/*`, and sometimes additionally an `.asc` - * file. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY" - * Files in the workspace matching any path pattern will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @return string - */ - public function getRepository() - { - return $this->repository; - } - - /** - * Artifact Registry repository, in the form - * "https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY" - * Files in the workspace matching any path pattern will be uploaded to - * Artifact Registry with this location as a prefix. - * - * Generated from protobuf field string repository = 1; - * @param string $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkString($var, True); - $this->repository = $var; - - return $this; - } - - /** - * Path globs used to match files in the build's workspace. For Python/ - * Twine, this is usually `dist/*`, and sometimes additionally an `.asc` - * file. - * - * Generated from protobuf field repeated string paths = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPaths() - { - return $this->paths; - } - - /** - * Path globs used to match files in the build's workspace. For Python/ - * Twine, this is usually `dist/*`, and sometimes additionally an `.asc` - * file. - * - * Generated from protobuf field repeated string paths = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPaths($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->paths = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PythonPackage::class, \Google\Cloud\Build\V1\Artifacts_PythonPackage::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_ArtifactObjects.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_ArtifactObjects.php deleted file mode 100644 index 9f697fa7976a..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Artifacts_ArtifactObjects.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.Build - */ -class Build extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The 'Build' name with format: - * `projects/{project}/locations/{location}/builds/{build}`, where {build} - * is a unique identifier generated by the service. - * - * Generated from protobuf field string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Unique identifier of the build. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $id = ''; - /** - * Output only. ID of the project. - * - * Generated from protobuf field string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $project_id = ''; - /** - * Output only. Status of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status = 0; - /** - * Output only. Customer-readable message about the current status. - * - * Generated from protobuf field string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_detail = ''; - /** - * The location of the source files to build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Source source = 3; - */ - protected $source = null; - /** - * Required. The operations to be performed on the workspace. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - private $steps; - /** - * Output only. Results of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $results = null; - /** - * Output only. Time at which the request to create the build was received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $start_time = null; - /** - * Output only. Time at which execution of the build was finished. - * The difference between finish_time and start_time is the duration of the - * build's execution. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $finish_time = null; - /** - * Amount of time that this build should be allowed to run, to second - * granularity. If this amount of time elapses, work on the build will cease - * and the build status will be `TIMEOUT`. - * `timeout` starts ticking from `startTime`. - * Default time is 60 minutes. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 12; - */ - protected $timeout = null; - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images are pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the `Build` resource's - * results field. - * If any of the images fail to be pushed, the build status is marked - * `FAILURE`. - * - * Generated from protobuf field repeated string images = 13; - */ - private $images; - /** - * TTL in queue for this build. If provided and the build is enqueued longer - * than this value, the build will expire and the build status will be - * `EXPIRED`. - * The TTL starts ticking from create_time. - * - * Generated from protobuf field .google.protobuf.Duration queue_ttl = 40; - */ - protected $queue_ttl = null; - /** - * Artifacts produced by the build that should be uploaded upon - * successful completion of all build steps. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - protected $artifacts = null; - /** - * Google Cloud Storage bucket where logs should be written (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. - * - * Generated from protobuf field string logs_bucket = 19; - */ - protected $logs_bucket = ''; - /** - * Output only. A permanent fixed identifier for source. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $source_provenance = null; - /** - * Output only. The ID of the `BuildTrigger` that triggered this build, if it - * was triggered automatically. - * - * Generated from protobuf field string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $build_trigger_id = ''; - /** - * Special options for this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - protected $options = null; - /** - * Output only. URL to logs for this build in Google Cloud Console. - * - * Generated from protobuf field string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $log_url = ''; - /** - * Substitutions data for `Build` resource. - * - * Generated from protobuf field map substitutions = 29; - */ - private $substitutions; - /** - * Tags for annotation of a `Build`. These are not docker tags. - * - * Generated from protobuf field repeated string tags = 31; - */ - private $tags; - /** - * Secrets to decrypt using Cloud Key Management Service. - * Note: Secret Manager is the recommended technique - * for managing sensitive data with Cloud Build. Use `available_secrets` to - * configure builds to access secrets from Secret Manager. For instructions, - * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - private $secrets; - /** - * Output only. Stores timing information for phases of the build. Valid keys - * are: - * * BUILD: time to execute all build steps. - * * PUSH: time to push all artifacts including docker images and non docker - * artifacts. - * * FETCHSOURCE: time to fetch source. - * * SETUPBUILD: time to set up build. - * If the build does not specify source or images, - * these keys will not be included. - * - * Generated from protobuf field map timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $timing; - /** - * Output only. Describes this build's approval configuration, status, - * and result. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $approval = null; - /** - * IAM service account whose credentials will be used at build runtime. - * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. - * ACCOUNT can be email address or uniqueId of the service account. - * - * Generated from protobuf field string service_account = 42 [(.google.api.resource_reference) = { - */ - protected $service_account = ''; - /** - * Secrets and secret environment variables. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - protected $available_secrets = null; - /** - * Output only. Non-fatal problems encountered during the execution of the - * build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $warnings; - /** - * Output only. Contains information about the build when status=FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $failure_info = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The 'Build' name with format: - * `projects/{project}/locations/{location}/builds/{build}`, where {build} - * is a unique identifier generated by the service. - * @type string $id - * Output only. Unique identifier of the build. - * @type string $project_id - * Output only. ID of the project. - * @type int $status - * Output only. Status of the build. - * @type string $status_detail - * Output only. Customer-readable message about the current status. - * @type \Google\Cloud\Build\V1\Source $source - * The location of the source files to build. - * @type array<\Google\Cloud\Build\V1\BuildStep>|\Google\Protobuf\Internal\RepeatedField $steps - * Required. The operations to be performed on the workspace. - * @type \Google\Cloud\Build\V1\Results $results - * Output only. Results of the build. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Time at which the request to create the build was received. - * @type \Google\Protobuf\Timestamp $start_time - * Output only. Time at which execution of the build was started. - * @type \Google\Protobuf\Timestamp $finish_time - * Output only. Time at which execution of the build was finished. - * The difference between finish_time and start_time is the duration of the - * build's execution. - * @type \Google\Protobuf\Duration $timeout - * Amount of time that this build should be allowed to run, to second - * granularity. If this amount of time elapses, work on the build will cease - * and the build status will be `TIMEOUT`. - * `timeout` starts ticking from `startTime`. - * Default time is 60 minutes. - * @type array|\Google\Protobuf\Internal\RepeatedField $images - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images are pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the `Build` resource's - * results field. - * If any of the images fail to be pushed, the build status is marked - * `FAILURE`. - * @type \Google\Protobuf\Duration $queue_ttl - * TTL in queue for this build. If provided and the build is enqueued longer - * than this value, the build will expire and the build status will be - * `EXPIRED`. - * The TTL starts ticking from create_time. - * @type \Google\Cloud\Build\V1\Artifacts $artifacts - * Artifacts produced by the build that should be uploaded upon - * successful completion of all build steps. - * @type string $logs_bucket - * Google Cloud Storage bucket where logs should be written (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. - * @type \Google\Cloud\Build\V1\SourceProvenance $source_provenance - * Output only. A permanent fixed identifier for source. - * @type string $build_trigger_id - * Output only. The ID of the `BuildTrigger` that triggered this build, if it - * was triggered automatically. - * @type \Google\Cloud\Build\V1\BuildOptions $options - * Special options for this build. - * @type string $log_url - * Output only. URL to logs for this build in Google Cloud Console. - * @type array|\Google\Protobuf\Internal\MapField $substitutions - * Substitutions data for `Build` resource. - * @type array|\Google\Protobuf\Internal\RepeatedField $tags - * Tags for annotation of a `Build`. These are not docker tags. - * @type array<\Google\Cloud\Build\V1\Secret>|\Google\Protobuf\Internal\RepeatedField $secrets - * Secrets to decrypt using Cloud Key Management Service. - * Note: Secret Manager is the recommended technique - * for managing sensitive data with Cloud Build. Use `available_secrets` to - * configure builds to access secrets from Secret Manager. For instructions, - * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets - * @type array|\Google\Protobuf\Internal\MapField $timing - * Output only. Stores timing information for phases of the build. Valid keys - * are: - * * BUILD: time to execute all build steps. - * * PUSH: time to push all artifacts including docker images and non docker - * artifacts. - * * FETCHSOURCE: time to fetch source. - * * SETUPBUILD: time to set up build. - * If the build does not specify source or images, - * these keys will not be included. - * @type \Google\Cloud\Build\V1\BuildApproval $approval - * Output only. Describes this build's approval configuration, status, - * and result. - * @type string $service_account - * IAM service account whose credentials will be used at build runtime. - * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. - * ACCOUNT can be email address or uniqueId of the service account. - * @type \Google\Cloud\Build\V1\Secrets $available_secrets - * Secrets and secret environment variables. - * @type array<\Google\Cloud\Build\V1\Build\Warning>|\Google\Protobuf\Internal\RepeatedField $warnings - * Output only. Non-fatal problems encountered during the execution of the - * build. - * @type \Google\Cloud\Build\V1\Build\FailureInfo $failure_info - * Output only. Contains information about the build when status=FAILURE. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The 'Build' name with format: - * `projects/{project}/locations/{location}/builds/{build}`, where {build} - * is a unique identifier generated by the service. - * - * Generated from protobuf field string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The 'Build' name with format: - * `projects/{project}/locations/{location}/builds/{build}`, where {build} - * is a unique identifier generated by the service. - * - * Generated from protobuf field string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Unique identifier of the build. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Output only. Unique identifier of the build. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Output only. ID of the project. - * - * Generated from protobuf field string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Output only. ID of the project. - * - * Generated from protobuf field string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Output only. Status of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * Output only. Status of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\Build\Status::class); - $this->status = $var; - - return $this; - } - - /** - * Output only. Customer-readable message about the current status. - * - * Generated from protobuf field string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusDetail() - { - return $this->status_detail; - } - - /** - * Output only. Customer-readable message about the current status. - * - * Generated from protobuf field string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusDetail($var) - { - GPBUtil::checkString($var, True); - $this->status_detail = $var; - - return $this; - } - - /** - * The location of the source files to build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Source source = 3; - * @return \Google\Cloud\Build\V1\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * The location of the source files to build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Source source = 3; - * @param \Google\Cloud\Build\V1\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Source::class); - $this->source = $var; - - return $this; - } - - /** - * Required. The operations to be performed on the workspace. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSteps() - { - return $this->steps; - } - - /** - * Required. The operations to be performed on the workspace. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - * @param array<\Google\Cloud\Build\V1\BuildStep>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSteps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\BuildStep::class); - $this->steps = $arr; - - return $this; - } - - /** - * Output only. Results of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\Results|null - */ - public function getResults() - { - return $this->results; - } - - public function hasResults() - { - return isset($this->results); - } - - public function clearResults() - { - unset($this->results); - } - - /** - * Output only. Results of the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\Results $var - * @return $this - */ - public function setResults($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Results::class); - $this->results = $var; - - return $this; - } - - /** - * Output only. Time at which the request to create the build was received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Time at which the request to create the build was received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Output only. Time at which execution of the build was started. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Output only. Time at which execution of the build was finished. - * The difference between finish_time and start_time is the duration of the - * build's execution. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getFinishTime() - { - return $this->finish_time; - } - - public function hasFinishTime() - { - return isset($this->finish_time); - } - - public function clearFinishTime() - { - unset($this->finish_time); - } - - /** - * Output only. Time at which execution of the build was finished. - * The difference between finish_time and start_time is the duration of the - * build's execution. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setFinishTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->finish_time = $var; - - return $this; - } - - /** - * Amount of time that this build should be allowed to run, to second - * granularity. If this amount of time elapses, work on the build will cease - * and the build status will be `TIMEOUT`. - * `timeout` starts ticking from `startTime`. - * Default time is 60 minutes. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 12; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Amount of time that this build should be allowed to run, to second - * granularity. If this amount of time elapses, work on the build will cease - * and the build status will be `TIMEOUT`. - * `timeout` starts ticking from `startTime`. - * Default time is 60 minutes. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 12; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images are pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the `Build` resource's - * results field. - * If any of the images fail to be pushed, the build status is marked - * `FAILURE`. - * - * Generated from protobuf field repeated string images = 13; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getImages() - { - return $this->images; - } - - /** - * A list of images to be pushed upon the successful completion of all build - * steps. - * The images are pushed using the builder service account's credentials. - * The digests of the pushed images will be stored in the `Build` resource's - * results field. - * If any of the images fail to be pushed, the build status is marked - * `FAILURE`. - * - * Generated from protobuf field repeated string images = 13; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setImages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->images = $arr; - - return $this; - } - - /** - * TTL in queue for this build. If provided and the build is enqueued longer - * than this value, the build will expire and the build status will be - * `EXPIRED`. - * The TTL starts ticking from create_time. - * - * Generated from protobuf field .google.protobuf.Duration queue_ttl = 40; - * @return \Google\Protobuf\Duration|null - */ - public function getQueueTtl() - { - return $this->queue_ttl; - } - - public function hasQueueTtl() - { - return isset($this->queue_ttl); - } - - public function clearQueueTtl() - { - unset($this->queue_ttl); - } - - /** - * TTL in queue for this build. If provided and the build is enqueued longer - * than this value, the build will expire and the build status will be - * `EXPIRED`. - * The TTL starts ticking from create_time. - * - * Generated from protobuf field .google.protobuf.Duration queue_ttl = 40; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setQueueTtl($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->queue_ttl = $var; - - return $this; - } - - /** - * Artifacts produced by the build that should be uploaded upon - * successful completion of all build steps. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * @return \Google\Cloud\Build\V1\Artifacts|null - */ - public function getArtifacts() - { - return $this->artifacts; - } - - public function hasArtifacts() - { - return isset($this->artifacts); - } - - public function clearArtifacts() - { - unset($this->artifacts); - } - - /** - * Artifacts produced by the build that should be uploaded upon - * successful completion of all build steps. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * @param \Google\Cloud\Build\V1\Artifacts $var - * @return $this - */ - public function setArtifacts($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Artifacts::class); - $this->artifacts = $var; - - return $this; - } - - /** - * Google Cloud Storage bucket where logs should be written (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. - * - * Generated from protobuf field string logs_bucket = 19; - * @return string - */ - public function getLogsBucket() - { - return $this->logs_bucket; - } - - /** - * Google Cloud Storage bucket where logs should be written (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. - * - * Generated from protobuf field string logs_bucket = 19; - * @param string $var - * @return $this - */ - public function setLogsBucket($var) - { - GPBUtil::checkString($var, True); - $this->logs_bucket = $var; - - return $this; - } - - /** - * Output only. A permanent fixed identifier for source. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\SourceProvenance|null - */ - public function getSourceProvenance() - { - return $this->source_provenance; - } - - public function hasSourceProvenance() - { - return isset($this->source_provenance); - } - - public function clearSourceProvenance() - { - unset($this->source_provenance); - } - - /** - * Output only. A permanent fixed identifier for source. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\SourceProvenance $var - * @return $this - */ - public function setSourceProvenance($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\SourceProvenance::class); - $this->source_provenance = $var; - - return $this; - } - - /** - * Output only. The ID of the `BuildTrigger` that triggered this build, if it - * was triggered automatically. - * - * Generated from protobuf field string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getBuildTriggerId() - { - return $this->build_trigger_id; - } - - /** - * Output only. The ID of the `BuildTrigger` that triggered this build, if it - * was triggered automatically. - * - * Generated from protobuf field string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setBuildTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->build_trigger_id = $var; - - return $this; - } - - /** - * Special options for this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * @return \Google\Cloud\Build\V1\BuildOptions|null - */ - public function getOptions() - { - return $this->options; - } - - public function hasOptions() - { - return isset($this->options); - } - - public function clearOptions() - { - unset($this->options); - } - - /** - * Special options for this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * @param \Google\Cloud\Build\V1\BuildOptions $var - * @return $this - */ - public function setOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\BuildOptions::class); - $this->options = $var; - - return $this; - } - - /** - * Output only. URL to logs for this build in Google Cloud Console. - * - * Generated from protobuf field string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getLogUrl() - { - return $this->log_url; - } - - /** - * Output only. URL to logs for this build in Google Cloud Console. - * - * Generated from protobuf field string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setLogUrl($var) - { - GPBUtil::checkString($var, True); - $this->log_url = $var; - - return $this; - } - - /** - * Substitutions data for `Build` resource. - * - * Generated from protobuf field map substitutions = 29; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSubstitutions() - { - return $this->substitutions; - } - - /** - * Substitutions data for `Build` resource. - * - * Generated from protobuf field map substitutions = 29; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSubstitutions($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->substitutions = $arr; - - return $this; - } - - /** - * Tags for annotation of a `Build`. These are not docker tags. - * - * Generated from protobuf field repeated string tags = 31; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTags() - { - return $this->tags; - } - - /** - * Tags for annotation of a `Build`. These are not docker tags. - * - * Generated from protobuf field repeated string tags = 31; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTags($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->tags = $arr; - - return $this; - } - - /** - * Secrets to decrypt using Cloud Key Management Service. - * Note: Secret Manager is the recommended technique - * for managing sensitive data with Cloud Build. Use `available_secrets` to - * configure builds to access secrets from Secret Manager. For instructions, - * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecrets() - { - return $this->secrets; - } - - /** - * Secrets to decrypt using Cloud Key Management Service. - * Note: Secret Manager is the recommended technique - * for managing sensitive data with Cloud Build. Use `available_secrets` to - * configure builds to access secrets from Secret Manager. For instructions, - * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - * @param array<\Google\Cloud\Build\V1\Secret>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecrets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Secret::class); - $this->secrets = $arr; - - return $this; - } - - /** - * Output only. Stores timing information for phases of the build. Valid keys - * are: - * * BUILD: time to execute all build steps. - * * PUSH: time to push all artifacts including docker images and non docker - * artifacts. - * * FETCHSOURCE: time to fetch source. - * * SETUPBUILD: time to set up build. - * If the build does not specify source or images, - * these keys will not be included. - * - * Generated from protobuf field map timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getTiming() - { - return $this->timing; - } - - /** - * Output only. Stores timing information for phases of the build. Valid keys - * are: - * * BUILD: time to execute all build steps. - * * PUSH: time to push all artifacts including docker images and non docker - * artifacts. - * * FETCHSOURCE: time to fetch source. - * * SETUPBUILD: time to set up build. - * If the build does not specify source or images, - * these keys will not be included. - * - * Generated from protobuf field map timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setTiming($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\TimeSpan::class); - $this->timing = $arr; - - return $this; - } - - /** - * Output only. Describes this build's approval configuration, status, - * and result. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\BuildApproval|null - */ - public function getApproval() - { - return $this->approval; - } - - public function hasApproval() - { - return isset($this->approval); - } - - public function clearApproval() - { - unset($this->approval); - } - - /** - * Output only. Describes this build's approval configuration, status, - * and result. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\BuildApproval $var - * @return $this - */ - public function setApproval($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\BuildApproval::class); - $this->approval = $var; - - return $this; - } - - /** - * IAM service account whose credentials will be used at build runtime. - * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. - * ACCOUNT can be email address or uniqueId of the service account. - * - * Generated from protobuf field string service_account = 42 [(.google.api.resource_reference) = { - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * IAM service account whose credentials will be used at build runtime. - * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. - * ACCOUNT can be email address or uniqueId of the service account. - * - * Generated from protobuf field string service_account = 42 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * Secrets and secret environment variables. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * @return \Google\Cloud\Build\V1\Secrets|null - */ - public function getAvailableSecrets() - { - return $this->available_secrets; - } - - public function hasAvailableSecrets() - { - return isset($this->available_secrets); - } - - public function clearAvailableSecrets() - { - unset($this->available_secrets); - } - - /** - * Secrets and secret environment variables. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * @param \Google\Cloud\Build\V1\Secrets $var - * @return $this - */ - public function setAvailableSecrets($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Secrets::class); - $this->available_secrets = $var; - - return $this; - } - - /** - * Output only. Non-fatal problems encountered during the execution of the - * build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWarnings() - { - return $this->warnings; - } - - /** - * Output only. Non-fatal problems encountered during the execution of the - * build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\Build\V1\Build\Warning>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWarnings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Build\Warning::class); - $this->warnings = $arr; - - return $this; - } - - /** - * Output only. Contains information about the build when status=FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\Build\FailureInfo|null - */ - public function getFailureInfo() - { - return $this->failure_info; - } - - public function hasFailureInfo() - { - return isset($this->failure_info); - } - - public function clearFailureInfo() - { - unset($this->failure_info); - } - - /** - * Output only. Contains information about the build when status=FAILURE. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\Build\FailureInfo $var - * @return $this - */ - public function setFailureInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Build\FailureInfo::class); - $this->failure_info = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo.php deleted file mode 100644 index fa0ea5fc7f43..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo.php +++ /dev/null @@ -1,104 +0,0 @@ -google.devtools.cloudbuild.v1.Build.FailureInfo - */ -class FailureInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the failure. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - */ - protected $type = 0; - /** - * Explains the failure issue in more detail using hard-coded text. - * - * Generated from protobuf field string detail = 2; - */ - protected $detail = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The name of the failure. - * @type string $detail - * Explains the failure issue in more detail using hard-coded text. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the failure. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The name of the failure. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\Build\FailureInfo\FailureType::class); - $this->type = $var; - - return $this; - } - - /** - * Explains the failure issue in more detail using hard-coded text. - * - * Generated from protobuf field string detail = 2; - * @return string - */ - public function getDetail() - { - return $this->detail; - } - - /** - * Explains the failure issue in more detail using hard-coded text. - * - * Generated from protobuf field string detail = 2; - * @param string $var - * @return $this - */ - public function setDetail($var) - { - GPBUtil::checkString($var, True); - $this->detail = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FailureInfo::class, \Google\Cloud\Build\V1\Build_FailureInfo::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo/FailureType.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo/FailureType.php deleted file mode 100644 index d7cdfc1a02de..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/FailureInfo/FailureType.php +++ /dev/null @@ -1,93 +0,0 @@ -google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType - */ -class FailureType -{ - /** - * Type unspecified - * - * Generated from protobuf enum FAILURE_TYPE_UNSPECIFIED = 0; - */ - const FAILURE_TYPE_UNSPECIFIED = 0; - /** - * Unable to push the image to the repository. - * - * Generated from protobuf enum PUSH_FAILED = 1; - */ - const PUSH_FAILED = 1; - /** - * Final image not found. - * - * Generated from protobuf enum PUSH_IMAGE_NOT_FOUND = 2; - */ - const PUSH_IMAGE_NOT_FOUND = 2; - /** - * Unauthorized push of the final image. - * - * Generated from protobuf enum PUSH_NOT_AUTHORIZED = 3; - */ - const PUSH_NOT_AUTHORIZED = 3; - /** - * Backend logging failures. Should retry. - * - * Generated from protobuf enum LOGGING_FAILURE = 4; - */ - const LOGGING_FAILURE = 4; - /** - * A build step has failed. - * - * Generated from protobuf enum USER_BUILD_STEP = 5; - */ - const USER_BUILD_STEP = 5; - /** - * The source fetching has failed. - * - * Generated from protobuf enum FETCH_SOURCE_FAILED = 6; - */ - const FETCH_SOURCE_FAILED = 6; - - private static $valueToName = [ - self::FAILURE_TYPE_UNSPECIFIED => 'FAILURE_TYPE_UNSPECIFIED', - self::PUSH_FAILED => 'PUSH_FAILED', - self::PUSH_IMAGE_NOT_FOUND => 'PUSH_IMAGE_NOT_FOUND', - self::PUSH_NOT_AUTHORIZED => 'PUSH_NOT_AUTHORIZED', - self::LOGGING_FAILURE => 'LOGGING_FAILURE', - self::USER_BUILD_STEP => 'USER_BUILD_STEP', - self::FETCH_SOURCE_FAILED => 'FETCH_SOURCE_FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FailureType::class, \Google\Cloud\Build\V1\Build_FailureInfo_FailureType::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Status.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Status.php deleted file mode 100644 index 67fa894b86cf..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Status.php +++ /dev/null @@ -1,114 +0,0 @@ -google.devtools.cloudbuild.v1.Build.Status - */ -class Status -{ - /** - * Status of the build is unknown. - * - * Generated from protobuf enum STATUS_UNKNOWN = 0; - */ - const STATUS_UNKNOWN = 0; - /** - * Build has been created and is pending execution and queuing. It has not - * been queued. - * - * Generated from protobuf enum PENDING = 10; - */ - const PENDING = 10; - /** - * Build or step is queued; work has not yet begun. - * - * Generated from protobuf enum QUEUED = 1; - */ - const QUEUED = 1; - /** - * Build or step is being executed. - * - * Generated from protobuf enum WORKING = 2; - */ - const WORKING = 2; - /** - * Build or step finished successfully. - * - * Generated from protobuf enum SUCCESS = 3; - */ - const SUCCESS = 3; - /** - * Build or step failed to complete successfully. - * - * Generated from protobuf enum FAILURE = 4; - */ - const FAILURE = 4; - /** - * Build or step failed due to an internal cause. - * - * Generated from protobuf enum INTERNAL_ERROR = 5; - */ - const INTERNAL_ERROR = 5; - /** - * Build or step took longer than was allowed. - * - * Generated from protobuf enum TIMEOUT = 6; - */ - const TIMEOUT = 6; - /** - * Build or step was canceled by a user. - * - * Generated from protobuf enum CANCELLED = 7; - */ - const CANCELLED = 7; - /** - * Build was enqueued for longer than the value of `queue_ttl`. - * - * Generated from protobuf enum EXPIRED = 9; - */ - const EXPIRED = 9; - - private static $valueToName = [ - self::STATUS_UNKNOWN => 'STATUS_UNKNOWN', - self::PENDING => 'PENDING', - self::QUEUED => 'QUEUED', - self::WORKING => 'WORKING', - self::SUCCESS => 'SUCCESS', - self::FAILURE => 'FAILURE', - self::INTERNAL_ERROR => 'INTERNAL_ERROR', - self::TIMEOUT => 'TIMEOUT', - self::CANCELLED => 'CANCELLED', - self::EXPIRED => 'EXPIRED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Status::class, \Google\Cloud\Build\V1\Build_Status::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning.php deleted file mode 100644 index 5568099389c3..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning.php +++ /dev/null @@ -1,104 +0,0 @@ -google.devtools.cloudbuild.v1.Build.Warning - */ -class Warning extends \Google\Protobuf\Internal\Message -{ - /** - * Explanation of the warning generated. - * - * Generated from protobuf field string text = 1; - */ - protected $text = ''; - /** - * The priority for this warning. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - */ - protected $priority = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $text - * Explanation of the warning generated. - * @type int $priority - * The priority for this warning. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Explanation of the warning generated. - * - * Generated from protobuf field string text = 1; - * @return string - */ - public function getText() - { - return $this->text; - } - - /** - * Explanation of the warning generated. - * - * Generated from protobuf field string text = 1; - * @param string $var - * @return $this - */ - public function setText($var) - { - GPBUtil::checkString($var, True); - $this->text = $var; - - return $this; - } - - /** - * The priority for this warning. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * @return int - */ - public function getPriority() - { - return $this->priority; - } - - /** - * The priority for this warning. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * @param int $var - * @return $this - */ - public function setPriority($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\Build\Warning\Priority::class); - $this->priority = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Warning::class, \Google\Cloud\Build\V1\Build_Warning::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning/Priority.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning/Priority.php deleted file mode 100644 index 798bd9dd8a31..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build/Warning/Priority.php +++ /dev/null @@ -1,71 +0,0 @@ -google.devtools.cloudbuild.v1.Build.Warning.Priority - */ -class Priority -{ - /** - * Should not be used. - * - * Generated from protobuf enum PRIORITY_UNSPECIFIED = 0; - */ - const PRIORITY_UNSPECIFIED = 0; - /** - * e.g. deprecation warnings and alternative feature highlights. - * - * Generated from protobuf enum INFO = 1; - */ - const INFO = 1; - /** - * e.g. automated detection of possible issues with the build. - * - * Generated from protobuf enum WARNING = 2; - */ - const WARNING = 2; - /** - * e.g. alerts that a feature used in the build is pending removal - * - * Generated from protobuf enum ALERT = 3; - */ - const ALERT = 3; - - private static $valueToName = [ - self::PRIORITY_UNSPECIFIED => 'PRIORITY_UNSPECIFIED', - self::INFO => 'INFO', - self::WARNING => 'WARNING', - self::ALERT => 'ALERT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Priority::class, \Google\Cloud\Build\V1\Build_Warning_Priority::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval.php deleted file mode 100644 index 36d49d7043d1..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval.php +++ /dev/null @@ -1,156 +0,0 @@ -google.devtools.cloudbuild.v1.BuildApproval - */ -class BuildApproval extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The state of this build's approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Configuration for manual approval of this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $config = null; - /** - * Output only. Result of manual approval for this Build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * Output only. The state of this build's approval. - * @type \Google\Cloud\Build\V1\ApprovalConfig $config - * Output only. Configuration for manual approval of this build. - * @type \Google\Cloud\Build\V1\ApprovalResult $result - * Output only. Result of manual approval for this Build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The state of this build's approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of this build's approval. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildApproval\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Configuration for manual approval of this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\ApprovalConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Output only. Configuration for manual approval of this build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\ApprovalConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\ApprovalConfig::class); - $this->config = $var; - - return $this; - } - - /** - * Output only. Result of manual approval for this Build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\ApprovalResult|null - */ - public function getResult() - { - return $this->result; - } - - public function hasResult() - { - return isset($this->result); - } - - public function clearResult() - { - unset($this->result); - } - - /** - * Output only. Result of manual approval for this Build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\ApprovalResult $var - * @return $this - */ - public function setResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\ApprovalResult::class); - $this->result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval/State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval/State.php deleted file mode 100644 index 7f2dcc9c3f4b..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval/State.php +++ /dev/null @@ -1,78 +0,0 @@ -google.devtools.cloudbuild.v1.BuildApproval.State - */ -class State -{ - /** - * Default enum type. This should not be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Build approval is pending. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * Build approval has been approved. - * - * Generated from protobuf enum APPROVED = 2; - */ - const APPROVED = 2; - /** - * Build approval has been rejected. - * - * Generated from protobuf enum REJECTED = 3; - */ - const REJECTED = 3; - /** - * Build was cancelled while it was still pending approval. - * - * Generated from protobuf enum CANCELLED = 5; - */ - const CANCELLED = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::APPROVED => 'APPROVED', - self::REJECTED => 'REJECTED', - self::CANCELLED => 'CANCELLED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Build\V1\BuildApproval_State::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval_State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval_State.php deleted file mode 100644 index 653e57aaa9ba..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildApproval_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOperationMetadata - */ -class BuildOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The build that the operation is tracking. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 1; - */ - protected $build = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V1\Build $build - * The build that the operation is tracking. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The build that the operation is tracking. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 1; - * @return \Google\Cloud\Build\V1\Build|null - */ - public function getBuild() - { - return $this->build; - } - - public function hasBuild() - { - return isset($this->build); - } - - public function clearBuild() - { - unset($this->build); - } - - /** - * The build that the operation is tracking. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 1; - * @param \Google\Cloud\Build\V1\Build $var - * @return $this - */ - public function setBuild($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Build::class); - $this->build = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions.php deleted file mode 100644 index b542e1645043..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions.php +++ /dev/null @@ -1,640 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions - */ -class BuildOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Requested hash for SourceProvenance. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - */ - private $source_provenance_hash; - /** - * Requested verifiability options. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - */ - protected $requested_verify_option = 0; - /** - * Compute Engine machine type on which to run the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - */ - protected $machine_type = 0; - /** - * Requested disk size for the VM that runs the build. Note that this is *NOT* - * "disk free"; some of the space will be used by the operating system and - * build utilities. Also note that this is the minimum disk size that will be - * allocated for the build -- the build may run with a larger disk than - * requested. At present, the maximum disk size is 2000GB; builds that request - * more than the maximum are rejected with an error. - * - * Generated from protobuf field int64 disk_size_gb = 6; - */ - protected $disk_size_gb = 0; - /** - * Option to specify behavior when there is an error in the substitution - * checks. - * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot - * be overridden in the build configuration file. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - */ - protected $substitution_option = 0; - /** - * Option to specify whether or not to apply bash style string - * operations to the substitutions. - * NOTE: this is always enabled for triggered builds and cannot be - * overridden in the build configuration file. - * - * Generated from protobuf field bool dynamic_substitutions = 17; - */ - protected $dynamic_substitutions = false; - /** - * Option to define build log streaming behavior to Google Cloud - * Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - */ - protected $log_streaming_option = 0; - /** - * This field deprecated; please use `pool.name` instead. - * - * Generated from protobuf field string worker_pool = 7 [deprecated = true]; - * @deprecated - */ - protected $worker_pool = ''; - /** - * Optional. Specification for execution on a `WorkerPool`. - * See [running builds in a private - * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - * for more information. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $pool = null; - /** - * Option to specify the logging mode, which determines if and where build - * logs are stored. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - */ - protected $logging = 0; - /** - * A list of global environment variable definitions that will exist for all - * build steps in this build. If a variable is defined in both globally and in - * a build step, the variable will use the build step value. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 12; - */ - private $env; - /** - * A list of global environment variables, which are encrypted using a Cloud - * Key Management Service crypto key. These values must be specified in the - * build's `Secret`. These variables will be available to all build steps - * in this build. - * - * Generated from protobuf field repeated string secret_env = 13; - */ - private $secret_env; - /** - * Global list of volumes to mount for ALL build steps - * Each volume is created as an empty volume prior to starting the build - * process. Upon completion of the build, volumes and their contents are - * discarded. Global volume names and paths cannot conflict with the volumes - * defined a build step. - * Using a global volume in a build with only one step is not valid as - * it is indicative of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - private $volumes; - /** - * Optional. Option to specify how default logs buckets are setup. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.DefaultLogsBucketBehavior default_logs_bucket_behavior = 21 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $default_logs_bucket_behavior = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $source_provenance_hash - * Requested hash for SourceProvenance. - * @type int $requested_verify_option - * Requested verifiability options. - * @type int $machine_type - * Compute Engine machine type on which to run the build. - * @type int|string $disk_size_gb - * Requested disk size for the VM that runs the build. Note that this is *NOT* - * "disk free"; some of the space will be used by the operating system and - * build utilities. Also note that this is the minimum disk size that will be - * allocated for the build -- the build may run with a larger disk than - * requested. At present, the maximum disk size is 2000GB; builds that request - * more than the maximum are rejected with an error. - * @type int $substitution_option - * Option to specify behavior when there is an error in the substitution - * checks. - * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot - * be overridden in the build configuration file. - * @type bool $dynamic_substitutions - * Option to specify whether or not to apply bash style string - * operations to the substitutions. - * NOTE: this is always enabled for triggered builds and cannot be - * overridden in the build configuration file. - * @type int $log_streaming_option - * Option to define build log streaming behavior to Google Cloud - * Storage. - * @type string $worker_pool - * This field deprecated; please use `pool.name` instead. - * @type \Google\Cloud\Build\V1\BuildOptions\PoolOption $pool - * Optional. Specification for execution on a `WorkerPool`. - * See [running builds in a private - * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - * for more information. - * @type int $logging - * Option to specify the logging mode, which determines if and where build - * logs are stored. - * @type array|\Google\Protobuf\Internal\RepeatedField $env - * A list of global environment variable definitions that will exist for all - * build steps in this build. If a variable is defined in both globally and in - * a build step, the variable will use the build step value. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * @type array|\Google\Protobuf\Internal\RepeatedField $secret_env - * A list of global environment variables, which are encrypted using a Cloud - * Key Management Service crypto key. These values must be specified in the - * build's `Secret`. These variables will be available to all build steps - * in this build. - * @type array<\Google\Cloud\Build\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $volumes - * Global list of volumes to mount for ALL build steps - * Each volume is created as an empty volume prior to starting the build - * process. Upon completion of the build, volumes and their contents are - * discarded. Global volume names and paths cannot conflict with the volumes - * defined a build step. - * Using a global volume in a build with only one step is not valid as - * it is indicative of a build request with an incorrect configuration. - * @type int $default_logs_bucket_behavior - * Optional. Option to specify how default logs buckets are setup. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Requested hash for SourceProvenance. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSourceProvenanceHash() - { - return $this->source_provenance_hash; - } - - /** - * Requested hash for SourceProvenance. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSourceProvenanceHash($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Build\V1\Hash\HashType::class); - $this->source_provenance_hash = $arr; - - return $this; - } - - /** - * Requested verifiability options. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * @return int - */ - public function getRequestedVerifyOption() - { - return $this->requested_verify_option; - } - - /** - * Requested verifiability options. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * @param int $var - * @return $this - */ - public function setRequestedVerifyOption($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\VerifyOption::class); - $this->requested_verify_option = $var; - - return $this; - } - - /** - * Compute Engine machine type on which to run the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * @return int - */ - public function getMachineType() - { - return $this->machine_type; - } - - /** - * Compute Engine machine type on which to run the build. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * @param int $var - * @return $this - */ - public function setMachineType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\MachineType::class); - $this->machine_type = $var; - - return $this; - } - - /** - * Requested disk size for the VM that runs the build. Note that this is *NOT* - * "disk free"; some of the space will be used by the operating system and - * build utilities. Also note that this is the minimum disk size that will be - * allocated for the build -- the build may run with a larger disk than - * requested. At present, the maximum disk size is 2000GB; builds that request - * more than the maximum are rejected with an error. - * - * Generated from protobuf field int64 disk_size_gb = 6; - * @return int|string - */ - public function getDiskSizeGb() - { - return $this->disk_size_gb; - } - - /** - * Requested disk size for the VM that runs the build. Note that this is *NOT* - * "disk free"; some of the space will be used by the operating system and - * build utilities. Also note that this is the minimum disk size that will be - * allocated for the build -- the build may run with a larger disk than - * requested. At present, the maximum disk size is 2000GB; builds that request - * more than the maximum are rejected with an error. - * - * Generated from protobuf field int64 disk_size_gb = 6; - * @param int|string $var - * @return $this - */ - public function setDiskSizeGb($var) - { - GPBUtil::checkInt64($var); - $this->disk_size_gb = $var; - - return $this; - } - - /** - * Option to specify behavior when there is an error in the substitution - * checks. - * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot - * be overridden in the build configuration file. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * @return int - */ - public function getSubstitutionOption() - { - return $this->substitution_option; - } - - /** - * Option to specify behavior when there is an error in the substitution - * checks. - * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot - * be overridden in the build configuration file. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * @param int $var - * @return $this - */ - public function setSubstitutionOption($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\SubstitutionOption::class); - $this->substitution_option = $var; - - return $this; - } - - /** - * Option to specify whether or not to apply bash style string - * operations to the substitutions. - * NOTE: this is always enabled for triggered builds and cannot be - * overridden in the build configuration file. - * - * Generated from protobuf field bool dynamic_substitutions = 17; - * @return bool - */ - public function getDynamicSubstitutions() - { - return $this->dynamic_substitutions; - } - - /** - * Option to specify whether or not to apply bash style string - * operations to the substitutions. - * NOTE: this is always enabled for triggered builds and cannot be - * overridden in the build configuration file. - * - * Generated from protobuf field bool dynamic_substitutions = 17; - * @param bool $var - * @return $this - */ - public function setDynamicSubstitutions($var) - { - GPBUtil::checkBool($var); - $this->dynamic_substitutions = $var; - - return $this; - } - - /** - * Option to define build log streaming behavior to Google Cloud - * Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * @return int - */ - public function getLogStreamingOption() - { - return $this->log_streaming_option; - } - - /** - * Option to define build log streaming behavior to Google Cloud - * Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * @param int $var - * @return $this - */ - public function setLogStreamingOption($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\LogStreamingOption::class); - $this->log_streaming_option = $var; - - return $this; - } - - /** - * This field deprecated; please use `pool.name` instead. - * - * Generated from protobuf field string worker_pool = 7 [deprecated = true]; - * @return string - * @deprecated - */ - public function getWorkerPool() - { - @trigger_error('worker_pool is deprecated.', E_USER_DEPRECATED); - return $this->worker_pool; - } - - /** - * This field deprecated; please use `pool.name` instead. - * - * Generated from protobuf field string worker_pool = 7 [deprecated = true]; - * @param string $var - * @return $this - * @deprecated - */ - public function setWorkerPool($var) - { - @trigger_error('worker_pool is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->worker_pool = $var; - - return $this; - } - - /** - * Optional. Specification for execution on a `WorkerPool`. - * See [running builds in a private - * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - * for more information. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Build\V1\BuildOptions\PoolOption|null - */ - public function getPool() - { - return $this->pool; - } - - public function hasPool() - { - return isset($this->pool); - } - - public function clearPool() - { - unset($this->pool); - } - - /** - * Optional. Specification for execution on a `WorkerPool`. - * See [running builds in a private - * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - * for more information. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Build\V1\BuildOptions\PoolOption $var - * @return $this - */ - public function setPool($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\BuildOptions\PoolOption::class); - $this->pool = $var; - - return $this; - } - - /** - * Option to specify the logging mode, which determines if and where build - * logs are stored. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * @return int - */ - public function getLogging() - { - return $this->logging; - } - - /** - * Option to specify the logging mode, which determines if and where build - * logs are stored. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * @param int $var - * @return $this - */ - public function setLogging($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\LoggingMode::class); - $this->logging = $var; - - return $this; - } - - /** - * A list of global environment variable definitions that will exist for all - * build steps in this build. If a variable is defined in both globally and in - * a build step, the variable will use the build step value. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 12; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnv() - { - return $this->env; - } - - /** - * A list of global environment variable definitions that will exist for all - * build steps in this build. If a variable is defined in both globally and in - * a build step, the variable will use the build step value. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 12; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnv($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->env = $arr; - - return $this; - } - - /** - * A list of global environment variables, which are encrypted using a Cloud - * Key Management Service crypto key. These values must be specified in the - * build's `Secret`. These variables will be available to all build steps - * in this build. - * - * Generated from protobuf field repeated string secret_env = 13; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecretEnv() - { - return $this->secret_env; - } - - /** - * A list of global environment variables, which are encrypted using a Cloud - * Key Management Service crypto key. These values must be specified in the - * build's `Secret`. These variables will be available to all build steps - * in this build. - * - * Generated from protobuf field repeated string secret_env = 13; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecretEnv($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->secret_env = $arr; - - return $this; - } - - /** - * Global list of volumes to mount for ALL build steps - * Each volume is created as an empty volume prior to starting the build - * process. Upon completion of the build, volumes and their contents are - * discarded. Global volume names and paths cannot conflict with the volumes - * defined a build step. - * Using a global volume in a build with only one step is not valid as - * it is indicative of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVolumes() - { - return $this->volumes; - } - - /** - * Global list of volumes to mount for ALL build steps - * Each volume is created as an empty volume prior to starting the build - * process. Upon completion of the build, volumes and their contents are - * discarded. Global volume names and paths cannot conflict with the volumes - * defined a build step. - * Using a global volume in a build with only one step is not valid as - * it is indicative of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - * @param array<\Google\Cloud\Build\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVolumes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Volume::class); - $this->volumes = $arr; - - return $this; - } - - /** - * Optional. Option to specify how default logs buckets are setup. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.DefaultLogsBucketBehavior default_logs_bucket_behavior = 21 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getDefaultLogsBucketBehavior() - { - return $this->default_logs_bucket_behavior; - } - - /** - * Optional. Option to specify how default logs buckets are setup. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildOptions.DefaultLogsBucketBehavior default_logs_bucket_behavior = 21 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setDefaultLogsBucketBehavior($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\BuildOptions\DefaultLogsBucketBehavior::class); - $this->default_logs_bucket_behavior = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/DefaultLogsBucketBehavior.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/DefaultLogsBucketBehavior.php deleted file mode 100644 index 6d139a8e98c5..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/DefaultLogsBucketBehavior.php +++ /dev/null @@ -1,59 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.DefaultLogsBucketBehavior - */ -class DefaultLogsBucketBehavior -{ - /** - * Unspecified. - * - * Generated from protobuf enum DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED = 0; - */ - const DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED = 0; - /** - * Bucket is located in user-owned project in the same region as the - * build. The builder service account must have access to create and write - * to GCS buckets in the build project. - * - * Generated from protobuf enum REGIONAL_USER_OWNED_BUCKET = 1; - */ - const REGIONAL_USER_OWNED_BUCKET = 1; - - private static $valueToName = [ - self::DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED => 'DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED', - self::REGIONAL_USER_OWNED_BUCKET => 'REGIONAL_USER_OWNED_BUCKET', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DefaultLogsBucketBehavior::class, \Google\Cloud\Build\V1\BuildOptions_DefaultLogsBucketBehavior::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LogStreamingOption.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LogStreamingOption.php deleted file mode 100644 index 2a3f9a0ddc0c..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LogStreamingOption.php +++ /dev/null @@ -1,65 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption - */ -class LogStreamingOption -{ - /** - * Service may automatically determine build log streaming behavior. - * - * Generated from protobuf enum STREAM_DEFAULT = 0; - */ - const STREAM_DEFAULT = 0; - /** - * Build logs should be streamed to Google Cloud Storage. - * - * Generated from protobuf enum STREAM_ON = 1; - */ - const STREAM_ON = 1; - /** - * Build logs should not be streamed to Google Cloud Storage; they will be - * written when the build is completed. - * - * Generated from protobuf enum STREAM_OFF = 2; - */ - const STREAM_OFF = 2; - - private static $valueToName = [ - self::STREAM_DEFAULT => 'STREAM_DEFAULT', - self::STREAM_ON => 'STREAM_ON', - self::STREAM_OFF => 'STREAM_OFF', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LogStreamingOption::class, \Google\Cloud\Build\V1\BuildOptions_LogStreamingOption::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LoggingMode.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LoggingMode.php deleted file mode 100644 index 14d794dbf5d1..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/LoggingMode.php +++ /dev/null @@ -1,88 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.LoggingMode - */ -class LoggingMode -{ - /** - * The service determines the logging mode. The default is `LEGACY`. Do not - * rely on the default logging behavior as it may change in the future. - * - * Generated from protobuf enum LOGGING_UNSPECIFIED = 0; - */ - const LOGGING_UNSPECIFIED = 0; - /** - * Build logs are stored in Cloud Logging and Cloud Storage. - * - * Generated from protobuf enum LEGACY = 1; - */ - const LEGACY = 1; - /** - * Build logs are stored in Cloud Storage. - * - * Generated from protobuf enum GCS_ONLY = 2; - */ - const GCS_ONLY = 2; - /** - * This option is the same as CLOUD_LOGGING_ONLY. - * - * Generated from protobuf enum STACKDRIVER_ONLY = 3 [deprecated = true]; - */ - const STACKDRIVER_ONLY = 3; - /** - * Build logs are stored in Cloud Logging. Selecting this option will not - * allow [logs - * streaming](https://cloud.google.com/sdk/gcloud/reference/builds/log). - * - * Generated from protobuf enum CLOUD_LOGGING_ONLY = 5; - */ - const CLOUD_LOGGING_ONLY = 5; - /** - * Turn off all logging. No build logs will be captured. - * - * Generated from protobuf enum NONE = 4; - */ - const NONE = 4; - - private static $valueToName = [ - self::LOGGING_UNSPECIFIED => 'LOGGING_UNSPECIFIED', - self::LEGACY => 'LEGACY', - self::GCS_ONLY => 'GCS_ONLY', - self::STACKDRIVER_ONLY => 'STACKDRIVER_ONLY', - self::CLOUD_LOGGING_ONLY => 'CLOUD_LOGGING_ONLY', - self::NONE => 'NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(LoggingMode::class, \Google\Cloud\Build\V1\BuildOptions_LoggingMode::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/MachineType.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/MachineType.php deleted file mode 100644 index e8ee9da697b1..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/MachineType.php +++ /dev/null @@ -1,80 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.MachineType - */ -class MachineType -{ - /** - * Standard machine type. - * - * Generated from protobuf enum UNSPECIFIED = 0; - */ - const UNSPECIFIED = 0; - /** - * Highcpu machine with 8 CPUs. - * - * Generated from protobuf enum N1_HIGHCPU_8 = 1; - */ - const N1_HIGHCPU_8 = 1; - /** - * Highcpu machine with 32 CPUs. - * - * Generated from protobuf enum N1_HIGHCPU_32 = 2; - */ - const N1_HIGHCPU_32 = 2; - /** - * Highcpu e2 machine with 8 CPUs. - * - * Generated from protobuf enum E2_HIGHCPU_8 = 5; - */ - const E2_HIGHCPU_8 = 5; - /** - * Highcpu e2 machine with 32 CPUs. - * - * Generated from protobuf enum E2_HIGHCPU_32 = 6; - */ - const E2_HIGHCPU_32 = 6; - - private static $valueToName = [ - self::UNSPECIFIED => 'UNSPECIFIED', - self::N1_HIGHCPU_8 => 'N1_HIGHCPU_8', - self::N1_HIGHCPU_32 => 'N1_HIGHCPU_32', - self::E2_HIGHCPU_8 => 'E2_HIGHCPU_8', - self::E2_HIGHCPU_32 => 'E2_HIGHCPU_32', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MachineType::class, \Google\Cloud\Build\V1\BuildOptions_MachineType::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/PoolOption.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/PoolOption.php deleted file mode 100644 index bb7bb9af80f6..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/PoolOption.php +++ /dev/null @@ -1,85 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.PoolOption - */ -class PoolOption extends \Google\Protobuf\Internal\Message -{ - /** - * The `WorkerPool` resource to execute the build on. - * You must have `cloudbuild.workerpools.use` on the project hosting the - * WorkerPool. - * Format projects/{project}/locations/{location}/workerPools/{workerPoolId} - * - * Generated from protobuf field string name = 1 [(.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The `WorkerPool` resource to execute the build on. - * You must have `cloudbuild.workerpools.use` on the project hosting the - * WorkerPool. - * Format projects/{project}/locations/{location}/workerPools/{workerPoolId} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The `WorkerPool` resource to execute the build on. - * You must have `cloudbuild.workerpools.use` on the project hosting the - * WorkerPool. - * Format projects/{project}/locations/{location}/workerPools/{workerPoolId} - * - * Generated from protobuf field string name = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The `WorkerPool` resource to execute the build on. - * You must have `cloudbuild.workerpools.use` on the project hosting the - * WorkerPool. - * Format projects/{project}/locations/{location}/workerPools/{workerPoolId} - * - * Generated from protobuf field string name = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PoolOption::class, \Google\Cloud\Build\V1\BuildOptions_PoolOption::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/SubstitutionOption.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/SubstitutionOption.php deleted file mode 100644 index 822546c92aee..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/SubstitutionOption.php +++ /dev/null @@ -1,58 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption - */ -class SubstitutionOption -{ - /** - * Fails the build if error in substitutions checks, like missing - * a substitution in the template or in the map. - * - * Generated from protobuf enum MUST_MATCH = 0; - */ - const MUST_MATCH = 0; - /** - * Do not fail the build if error in substitutions checks. - * - * Generated from protobuf enum ALLOW_LOOSE = 1; - */ - const ALLOW_LOOSE = 1; - - private static $valueToName = [ - self::MUST_MATCH => 'MUST_MATCH', - self::ALLOW_LOOSE => 'ALLOW_LOOSE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SubstitutionOption::class, \Google\Cloud\Build\V1\BuildOptions_SubstitutionOption::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/VerifyOption.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/VerifyOption.php deleted file mode 100644 index 3479ddbf9cf2..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions/VerifyOption.php +++ /dev/null @@ -1,57 +0,0 @@ -google.devtools.cloudbuild.v1.BuildOptions.VerifyOption - */ -class VerifyOption -{ - /** - * Not a verifiable build (the default). - * - * Generated from protobuf enum NOT_VERIFIED = 0; - */ - const NOT_VERIFIED = 0; - /** - * Build must be verified. - * - * Generated from protobuf enum VERIFIED = 1; - */ - const VERIFIED = 1; - - private static $valueToName = [ - self::NOT_VERIFIED => 'NOT_VERIFIED', - self::VERIFIED => 'VERIFIED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(VerifyOption::class, \Google\Cloud\Build\V1\BuildOptions_VerifyOption::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_DefaultLogsBucketBehavior.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_DefaultLogsBucketBehavior.php deleted file mode 100644 index 40cc863f04f1..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildOptions_DefaultLogsBucketBehavior.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.BuildStep - */ -class BuildStep extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the container image that will run this particular - * build step. - * If the image is available in the host's Docker daemon's cache, it - * will be run directly. If not, the host will attempt to pull the image - * first, using the builder service account's credentials if necessary. - * The Docker daemon's cache will already have the latest versions of all of - * the officially supported build steps - * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). - * The Docker daemon will also have cached many of the layers for some popular - * images, like "ubuntu", "debian", but they will be refreshed at the time you - * attempt to use them. - * If you built an image in a previous build step, it will be stored in the - * host's Docker daemon's cache and is available to use as the name for a - * later build step. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A list of environment variable definitions to be used when running a step. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 2; - */ - private $env; - /** - * A list of arguments that will be presented to the step when it is started. - * If the image used to run the step's container has an entrypoint, the `args` - * are used as arguments to that entrypoint. If the image does not define - * an entrypoint, the first element in args is used as the entrypoint, - * and the remainder will be used as arguments. - * - * Generated from protobuf field repeated string args = 3; - */ - private $args; - /** - * Working directory to use when running this step's container. - * If this value is a relative path, it is relative to the build's working - * directory. If this value is absolute, it may be outside the build's working - * directory, in which case the contents of the path may not be persisted - * across build step executions, unless a `volume` for that path is specified. - * If the build specifies a `RepoSource` with `dir` and a step with a `dir`, - * which specifies an absolute path, the `RepoSource` `dir` is ignored for - * the step's execution. - * - * Generated from protobuf field string dir = 4; - */ - protected $dir = ''; - /** - * Unique identifier for this build step, used in `wait_for` to - * reference this build step as a dependency. - * - * Generated from protobuf field string id = 5; - */ - protected $id = ''; - /** - * The ID(s) of the step(s) that this build step depends on. - * This build step will not start until all the build steps in `wait_for` - * have completed successfully. If `wait_for` is empty, this build step will - * start when all previous build steps in the `Build.Steps` list have - * completed successfully. - * - * Generated from protobuf field repeated string wait_for = 6; - */ - private $wait_for; - /** - * Entrypoint to be used instead of the build step image's default entrypoint. - * If unset, the image's default entrypoint is used. - * - * Generated from protobuf field string entrypoint = 7; - */ - protected $entrypoint = ''; - /** - * A list of environment variables which are encrypted using a Cloud Key - * Management Service crypto key. These values must be specified in the - * build's `Secret`. - * - * Generated from protobuf field repeated string secret_env = 8; - */ - private $secret_env; - /** - * List of volumes to mount into the build step. - * Each volume is created as an empty volume prior to execution of the - * build step. Upon completion of the build, volumes and their contents are - * discarded. - * Using a named volume in only one step is not valid as it is indicative - * of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - private $volumes; - /** - * Output only. Stores timing information for executing this build step. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $timing = null; - /** - * Output only. Stores timing information for pulling this build step's - * builder image only. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pull_timing = null; - /** - * Time limit for executing this build step. If not defined, the step has no - * time limit and will be allowed to continue to run until either it completes - * or the build itself times out. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 11; - */ - protected $timeout = null; - /** - * Output only. Status of the build step. At this time, build step status is - * only updated on build completion; step status is not updated in real-time - * as the build progresses. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status = 0; - /** - * Allow this build step to fail without failing the entire build. - * If false, the entire build will fail if this step fails. Otherwise, the - * build will succeed, but this step will still have a failure status. - * Error information will be reported in the failure_detail field. - * - * Generated from protobuf field bool allow_failure = 14; - */ - protected $allow_failure = false; - /** - * Output only. Return code from running the step. - * - * Generated from protobuf field int32 exit_code = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $exit_code = 0; - /** - * Allow this build step to fail without failing the entire build if and - * only if the exit code is one of the specified codes. If allow_failure - * is also specified, this field will take precedence. - * - * Generated from protobuf field repeated int32 allow_exit_codes = 18; - */ - private $allow_exit_codes; - /** - * A shell script to be executed in the step. - * When script is provided, the user cannot specify the entrypoint or args. - * - * Generated from protobuf field string script = 19; - */ - protected $script = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the container image that will run this particular - * build step. - * If the image is available in the host's Docker daemon's cache, it - * will be run directly. If not, the host will attempt to pull the image - * first, using the builder service account's credentials if necessary. - * The Docker daemon's cache will already have the latest versions of all of - * the officially supported build steps - * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). - * The Docker daemon will also have cached many of the layers for some popular - * images, like "ubuntu", "debian", but they will be refreshed at the time you - * attempt to use them. - * If you built an image in a previous build step, it will be stored in the - * host's Docker daemon's cache and is available to use as the name for a - * later build step. - * @type array|\Google\Protobuf\Internal\RepeatedField $env - * A list of environment variable definitions to be used when running a step. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * @type array|\Google\Protobuf\Internal\RepeatedField $args - * A list of arguments that will be presented to the step when it is started. - * If the image used to run the step's container has an entrypoint, the `args` - * are used as arguments to that entrypoint. If the image does not define - * an entrypoint, the first element in args is used as the entrypoint, - * and the remainder will be used as arguments. - * @type string $dir - * Working directory to use when running this step's container. - * If this value is a relative path, it is relative to the build's working - * directory. If this value is absolute, it may be outside the build's working - * directory, in which case the contents of the path may not be persisted - * across build step executions, unless a `volume` for that path is specified. - * If the build specifies a `RepoSource` with `dir` and a step with a `dir`, - * which specifies an absolute path, the `RepoSource` `dir` is ignored for - * the step's execution. - * @type string $id - * Unique identifier for this build step, used in `wait_for` to - * reference this build step as a dependency. - * @type array|\Google\Protobuf\Internal\RepeatedField $wait_for - * The ID(s) of the step(s) that this build step depends on. - * This build step will not start until all the build steps in `wait_for` - * have completed successfully. If `wait_for` is empty, this build step will - * start when all previous build steps in the `Build.Steps` list have - * completed successfully. - * @type string $entrypoint - * Entrypoint to be used instead of the build step image's default entrypoint. - * If unset, the image's default entrypoint is used. - * @type array|\Google\Protobuf\Internal\RepeatedField $secret_env - * A list of environment variables which are encrypted using a Cloud Key - * Management Service crypto key. These values must be specified in the - * build's `Secret`. - * @type array<\Google\Cloud\Build\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $volumes - * List of volumes to mount into the build step. - * Each volume is created as an empty volume prior to execution of the - * build step. Upon completion of the build, volumes and their contents are - * discarded. - * Using a named volume in only one step is not valid as it is indicative - * of a build request with an incorrect configuration. - * @type \Google\Cloud\Build\V1\TimeSpan $timing - * Output only. Stores timing information for executing this build step. - * @type \Google\Cloud\Build\V1\TimeSpan $pull_timing - * Output only. Stores timing information for pulling this build step's - * builder image only. - * @type \Google\Protobuf\Duration $timeout - * Time limit for executing this build step. If not defined, the step has no - * time limit and will be allowed to continue to run until either it completes - * or the build itself times out. - * @type int $status - * Output only. Status of the build step. At this time, build step status is - * only updated on build completion; step status is not updated in real-time - * as the build progresses. - * @type bool $allow_failure - * Allow this build step to fail without failing the entire build. - * If false, the entire build will fail if this step fails. Otherwise, the - * build will succeed, but this step will still have a failure status. - * Error information will be reported in the failure_detail field. - * @type int $exit_code - * Output only. Return code from running the step. - * @type array|\Google\Protobuf\Internal\RepeatedField $allow_exit_codes - * Allow this build step to fail without failing the entire build if and - * only if the exit code is one of the specified codes. If allow_failure - * is also specified, this field will take precedence. - * @type string $script - * A shell script to be executed in the step. - * When script is provided, the user cannot specify the entrypoint or args. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the container image that will run this particular - * build step. - * If the image is available in the host's Docker daemon's cache, it - * will be run directly. If not, the host will attempt to pull the image - * first, using the builder service account's credentials if necessary. - * The Docker daemon's cache will already have the latest versions of all of - * the officially supported build steps - * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). - * The Docker daemon will also have cached many of the layers for some popular - * images, like "ubuntu", "debian", but they will be refreshed at the time you - * attempt to use them. - * If you built an image in a previous build step, it will be stored in the - * host's Docker daemon's cache and is available to use as the name for a - * later build step. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the container image that will run this particular - * build step. - * If the image is available in the host's Docker daemon's cache, it - * will be run directly. If not, the host will attempt to pull the image - * first, using the builder service account's credentials if necessary. - * The Docker daemon's cache will already have the latest versions of all of - * the officially supported build steps - * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). - * The Docker daemon will also have cached many of the layers for some popular - * images, like "ubuntu", "debian", but they will be refreshed at the time you - * attempt to use them. - * If you built an image in a previous build step, it will be stored in the - * host's Docker daemon's cache and is available to use as the name for a - * later build step. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A list of environment variable definitions to be used when running a step. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnv() - { - return $this->env; - } - - /** - * A list of environment variable definitions to be used when running a step. - * The elements are of the form "KEY=VALUE" for the environment variable "KEY" - * being given the value "VALUE". - * - * Generated from protobuf field repeated string env = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnv($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->env = $arr; - - return $this; - } - - /** - * A list of arguments that will be presented to the step when it is started. - * If the image used to run the step's container has an entrypoint, the `args` - * are used as arguments to that entrypoint. If the image does not define - * an entrypoint, the first element in args is used as the entrypoint, - * and the remainder will be used as arguments. - * - * Generated from protobuf field repeated string args = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArgs() - { - return $this->args; - } - - /** - * A list of arguments that will be presented to the step when it is started. - * If the image used to run the step's container has an entrypoint, the `args` - * are used as arguments to that entrypoint. If the image does not define - * an entrypoint, the first element in args is used as the entrypoint, - * and the remainder will be used as arguments. - * - * Generated from protobuf field repeated string args = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArgs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->args = $arr; - - return $this; - } - - /** - * Working directory to use when running this step's container. - * If this value is a relative path, it is relative to the build's working - * directory. If this value is absolute, it may be outside the build's working - * directory, in which case the contents of the path may not be persisted - * across build step executions, unless a `volume` for that path is specified. - * If the build specifies a `RepoSource` with `dir` and a step with a `dir`, - * which specifies an absolute path, the `RepoSource` `dir` is ignored for - * the step's execution. - * - * Generated from protobuf field string dir = 4; - * @return string - */ - public function getDir() - { - return $this->dir; - } - - /** - * Working directory to use when running this step's container. - * If this value is a relative path, it is relative to the build's working - * directory. If this value is absolute, it may be outside the build's working - * directory, in which case the contents of the path may not be persisted - * across build step executions, unless a `volume` for that path is specified. - * If the build specifies a `RepoSource` with `dir` and a step with a `dir`, - * which specifies an absolute path, the `RepoSource` `dir` is ignored for - * the step's execution. - * - * Generated from protobuf field string dir = 4; - * @param string $var - * @return $this - */ - public function setDir($var) - { - GPBUtil::checkString($var, True); - $this->dir = $var; - - return $this; - } - - /** - * Unique identifier for this build step, used in `wait_for` to - * reference this build step as a dependency. - * - * Generated from protobuf field string id = 5; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Unique identifier for this build step, used in `wait_for` to - * reference this build step as a dependency. - * - * Generated from protobuf field string id = 5; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The ID(s) of the step(s) that this build step depends on. - * This build step will not start until all the build steps in `wait_for` - * have completed successfully. If `wait_for` is empty, this build step will - * start when all previous build steps in the `Build.Steps` list have - * completed successfully. - * - * Generated from protobuf field repeated string wait_for = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWaitFor() - { - return $this->wait_for; - } - - /** - * The ID(s) of the step(s) that this build step depends on. - * This build step will not start until all the build steps in `wait_for` - * have completed successfully. If `wait_for` is empty, this build step will - * start when all previous build steps in the `Build.Steps` list have - * completed successfully. - * - * Generated from protobuf field repeated string wait_for = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWaitFor($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->wait_for = $arr; - - return $this; - } - - /** - * Entrypoint to be used instead of the build step image's default entrypoint. - * If unset, the image's default entrypoint is used. - * - * Generated from protobuf field string entrypoint = 7; - * @return string - */ - public function getEntrypoint() - { - return $this->entrypoint; - } - - /** - * Entrypoint to be used instead of the build step image's default entrypoint. - * If unset, the image's default entrypoint is used. - * - * Generated from protobuf field string entrypoint = 7; - * @param string $var - * @return $this - */ - public function setEntrypoint($var) - { - GPBUtil::checkString($var, True); - $this->entrypoint = $var; - - return $this; - } - - /** - * A list of environment variables which are encrypted using a Cloud Key - * Management Service crypto key. These values must be specified in the - * build's `Secret`. - * - * Generated from protobuf field repeated string secret_env = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecretEnv() - { - return $this->secret_env; - } - - /** - * A list of environment variables which are encrypted using a Cloud Key - * Management Service crypto key. These values must be specified in the - * build's `Secret`. - * - * Generated from protobuf field repeated string secret_env = 8; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecretEnv($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->secret_env = $arr; - - return $this; - } - - /** - * List of volumes to mount into the build step. - * Each volume is created as an empty volume prior to execution of the - * build step. Upon completion of the build, volumes and their contents are - * discarded. - * Using a named volume in only one step is not valid as it is indicative - * of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getVolumes() - { - return $this->volumes; - } - - /** - * List of volumes to mount into the build step. - * Each volume is created as an empty volume prior to execution of the - * build step. Upon completion of the build, volumes and their contents are - * discarded. - * Using a named volume in only one step is not valid as it is indicative - * of a build request with an incorrect configuration. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - * @param array<\Google\Cloud\Build\V1\Volume>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setVolumes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Volume::class); - $this->volumes = $arr; - - return $this; - } - - /** - * Output only. Stores timing information for executing this build step. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getTiming() - { - return $this->timing; - } - - public function hasTiming() - { - return isset($this->timing); - } - - public function clearTiming() - { - unset($this->timing); - } - - /** - * Output only. Stores timing information for executing this build step. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->timing = $var; - - return $this; - } - - /** - * Output only. Stores timing information for pulling this build step's - * builder image only. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getPullTiming() - { - return $this->pull_timing; - } - - public function hasPullTiming() - { - return isset($this->pull_timing); - } - - public function clearPullTiming() - { - unset($this->pull_timing); - } - - /** - * Output only. Stores timing information for pulling this build step's - * builder image only. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setPullTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->pull_timing = $var; - - return $this; - } - - /** - * Time limit for executing this build step. If not defined, the step has no - * time limit and will be allowed to continue to run until either it completes - * or the build itself times out. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 11; - * @return \Google\Protobuf\Duration|null - */ - public function getTimeout() - { - return $this->timeout; - } - - public function hasTimeout() - { - return isset($this->timeout); - } - - public function clearTimeout() - { - unset($this->timeout); - } - - /** - * Time limit for executing this build step. If not defined, the step has no - * time limit and will be allowed to continue to run until either it completes - * or the build itself times out. - * - * Generated from protobuf field .google.protobuf.Duration timeout = 11; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->timeout = $var; - - return $this; - } - - /** - * Output only. Status of the build step. At this time, build step status is - * only updated on build completion; step status is not updated in real-time - * as the build progresses. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * Output only. Status of the build step. At this time, build step status is - * only updated on build completion; step status is not updated in real-time - * as the build progresses. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\Build\Status::class); - $this->status = $var; - - return $this; - } - - /** - * Allow this build step to fail without failing the entire build. - * If false, the entire build will fail if this step fails. Otherwise, the - * build will succeed, but this step will still have a failure status. - * Error information will be reported in the failure_detail field. - * - * Generated from protobuf field bool allow_failure = 14; - * @return bool - */ - public function getAllowFailure() - { - return $this->allow_failure; - } - - /** - * Allow this build step to fail without failing the entire build. - * If false, the entire build will fail if this step fails. Otherwise, the - * build will succeed, but this step will still have a failure status. - * Error information will be reported in the failure_detail field. - * - * Generated from protobuf field bool allow_failure = 14; - * @param bool $var - * @return $this - */ - public function setAllowFailure($var) - { - GPBUtil::checkBool($var); - $this->allow_failure = $var; - - return $this; - } - - /** - * Output only. Return code from running the step. - * - * Generated from protobuf field int32 exit_code = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getExitCode() - { - return $this->exit_code; - } - - /** - * Output only. Return code from running the step. - * - * Generated from protobuf field int32 exit_code = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setExitCode($var) - { - GPBUtil::checkInt32($var); - $this->exit_code = $var; - - return $this; - } - - /** - * Allow this build step to fail without failing the entire build if and - * only if the exit code is one of the specified codes. If allow_failure - * is also specified, this field will take precedence. - * - * Generated from protobuf field repeated int32 allow_exit_codes = 18; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAllowExitCodes() - { - return $this->allow_exit_codes; - } - - /** - * Allow this build step to fail without failing the entire build if and - * only if the exit code is one of the specified codes. If allow_failure - * is also specified, this field will take precedence. - * - * Generated from protobuf field repeated int32 allow_exit_codes = 18; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAllowExitCodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->allow_exit_codes = $arr; - - return $this; - } - - /** - * A shell script to be executed in the step. - * When script is provided, the user cannot specify the entrypoint or args. - * - * Generated from protobuf field string script = 19; - * @return string - */ - public function getScript() - { - return $this->script; - } - - /** - * A shell script to be executed in the step. - * When script is provided, the user cannot specify the entrypoint or args. - * - * Generated from protobuf field string script = 19; - * @param string $var - * @return $this - */ - public function setScript($var) - { - GPBUtil::checkString($var, True); - $this->script = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildTrigger.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildTrigger.php deleted file mode 100644 index 9daccd3f6dcf..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/BuildTrigger.php +++ /dev/null @@ -1,881 +0,0 @@ -google.devtools.cloudbuild.v1.BuildTrigger - */ -class BuildTrigger extends \Google\Protobuf\Internal\Message -{ - /** - * The `Trigger` name with format: - * `projects/{project}/locations/{location}/triggers/{trigger}`, where - * {trigger} is a unique identifier generated by the service. - * - * Generated from protobuf field string resource_name = 34; - */ - protected $resource_name = ''; - /** - * Output only. Unique identifier of the trigger. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $id = ''; - /** - * Human-readable description of this trigger. - * - * Generated from protobuf field string description = 10; - */ - protected $description = ''; - /** - * User-assigned name of the trigger. Must be unique within the project. - * Trigger names must meet the following requirements: - * + They must contain only alphanumeric characters and dashes. - * + They can be 1-64 characters long. - * + They must begin and end with an alphanumeric character. - * - * Generated from protobuf field string name = 21; - */ - protected $name = ''; - /** - * Tags for annotation of a `BuildTrigger` - * - * Generated from protobuf field repeated string tags = 19; - */ - private $tags; - /** - * Template describing the types of source changes to trigger a build. - * Branch and tag names in trigger templates are interpreted as regular - * expressions. Any branch or tag change that matches that regular expression - * will trigger a build. - * Mutually exclusive with `github`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - protected $trigger_template = null; - /** - * GitHubEventsConfig describes the configuration of a trigger that creates - * a build whenever a GitHub event is received. - * Mutually exclusive with `trigger_template`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - protected $github = null; - /** - * PubsubConfig describes the configuration of a trigger that - * creates a build whenever a Pub/Sub message is published. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - protected $pubsub_config = null; - /** - * WebhookConfig describes the configuration of a trigger that - * creates a build whenever a webhook is sent to a trigger's webhook URL. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - protected $webhook_config = null; - /** - * Output only. Time when the trigger was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * If true, the trigger will never automatically execute a build. - * - * Generated from protobuf field bool disabled = 9; - */ - protected $disabled = false; - /** - * Substitutions for Build resource. The keys must match the following - * regular expression: `^_[A-Z0-9_]+$`. - * - * Generated from protobuf field map substitutions = 11; - */ - private $substitutions; - /** - * ignored_files and included_files are file glob matches using - * https://golang.org/pkg/path/filepath/#Match extended with support for "**". - * If ignored_files and changed files are both empty, then they are - * not used to determine whether or not to trigger a build. - * If ignored_files is not empty, then we ignore any files that match - * any of the ignored_file globs. If the change has no files that are - * outside of the ignored_files globs, then we do not trigger a build. - * - * Generated from protobuf field repeated string ignored_files = 15; - */ - private $ignored_files; - /** - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is empty, then as far as this filter is - * concerned, we should trigger the build. - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is not empty, then we make sure that at - * least one of those files matches a included_files glob. If not, - * then we do not trigger a build. - * - * Generated from protobuf field repeated string included_files = 16; - */ - private $included_files; - /** - * Optional. A Common Expression Language string. - * - * Generated from protobuf field string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * The service account used for all user-controlled operations including - * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - * If no service account is set, then the standard Cloud Build service account - * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. - * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` - * - * Generated from protobuf field string service_account = 33 [(.google.api.resource_reference) = { - */ - protected $service_account = ''; - protected $build_template; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_name - * The `Trigger` name with format: - * `projects/{project}/locations/{location}/triggers/{trigger}`, where - * {trigger} is a unique identifier generated by the service. - * @type string $id - * Output only. Unique identifier of the trigger. - * @type string $description - * Human-readable description of this trigger. - * @type string $name - * User-assigned name of the trigger. Must be unique within the project. - * Trigger names must meet the following requirements: - * + They must contain only alphanumeric characters and dashes. - * + They can be 1-64 characters long. - * + They must begin and end with an alphanumeric character. - * @type array|\Google\Protobuf\Internal\RepeatedField $tags - * Tags for annotation of a `BuildTrigger` - * @type \Google\Cloud\Build\V1\RepoSource $trigger_template - * Template describing the types of source changes to trigger a build. - * Branch and tag names in trigger templates are interpreted as regular - * expressions. Any branch or tag change that matches that regular expression - * will trigger a build. - * Mutually exclusive with `github`. - * @type \Google\Cloud\Build\V1\GitHubEventsConfig $github - * GitHubEventsConfig describes the configuration of a trigger that creates - * a build whenever a GitHub event is received. - * Mutually exclusive with `trigger_template`. - * @type \Google\Cloud\Build\V1\PubsubConfig $pubsub_config - * PubsubConfig describes the configuration of a trigger that - * creates a build whenever a Pub/Sub message is published. - * @type \Google\Cloud\Build\V1\WebhookConfig $webhook_config - * WebhookConfig describes the configuration of a trigger that - * creates a build whenever a webhook is sent to a trigger's webhook URL. - * @type bool $autodetect - * Autodetect build configuration. The following precedence is used (case - * insensitive): - * 1. cloudbuild.yaml - * 2. cloudbuild.yml - * 3. cloudbuild.json - * 4. Dockerfile - * Currently only available for GitHub App Triggers. - * @type \Google\Cloud\Build\V1\Build $build - * Contents of the build template. - * @type string $filename - * Path, from the source root, to the build configuration file - * (i.e. cloudbuild.yaml). - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Time when the trigger was created. - * @type bool $disabled - * If true, the trigger will never automatically execute a build. - * @type array|\Google\Protobuf\Internal\MapField $substitutions - * Substitutions for Build resource. The keys must match the following - * regular expression: `^_[A-Z0-9_]+$`. - * @type array|\Google\Protobuf\Internal\RepeatedField $ignored_files - * ignored_files and included_files are file glob matches using - * https://golang.org/pkg/path/filepath/#Match extended with support for "**". - * If ignored_files and changed files are both empty, then they are - * not used to determine whether or not to trigger a build. - * If ignored_files is not empty, then we ignore any files that match - * any of the ignored_file globs. If the change has no files that are - * outside of the ignored_files globs, then we do not trigger a build. - * @type array|\Google\Protobuf\Internal\RepeatedField $included_files - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is empty, then as far as this filter is - * concerned, we should trigger the build. - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is not empty, then we make sure that at - * least one of those files matches a included_files glob. If not, - * then we do not trigger a build. - * @type string $filter - * Optional. A Common Expression Language string. - * @type string $service_account - * The service account used for all user-controlled operations including - * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - * If no service account is set, then the standard Cloud Build service account - * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. - * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The `Trigger` name with format: - * `projects/{project}/locations/{location}/triggers/{trigger}`, where - * {trigger} is a unique identifier generated by the service. - * - * Generated from protobuf field string resource_name = 34; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * The `Trigger` name with format: - * `projects/{project}/locations/{location}/triggers/{trigger}`, where - * {trigger} is a unique identifier generated by the service. - * - * Generated from protobuf field string resource_name = 34; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * Output only. Unique identifier of the trigger. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Output only. Unique identifier of the trigger. - * - * Generated from protobuf field string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Human-readable description of this trigger. - * - * Generated from protobuf field string description = 10; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Human-readable description of this trigger. - * - * Generated from protobuf field string description = 10; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * User-assigned name of the trigger. Must be unique within the project. - * Trigger names must meet the following requirements: - * + They must contain only alphanumeric characters and dashes. - * + They can be 1-64 characters long. - * + They must begin and end with an alphanumeric character. - * - * Generated from protobuf field string name = 21; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * User-assigned name of the trigger. Must be unique within the project. - * Trigger names must meet the following requirements: - * + They must contain only alphanumeric characters and dashes. - * + They can be 1-64 characters long. - * + They must begin and end with an alphanumeric character. - * - * Generated from protobuf field string name = 21; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Tags for annotation of a `BuildTrigger` - * - * Generated from protobuf field repeated string tags = 19; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTags() - { - return $this->tags; - } - - /** - * Tags for annotation of a `BuildTrigger` - * - * Generated from protobuf field repeated string tags = 19; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTags($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->tags = $arr; - - return $this; - } - - /** - * Template describing the types of source changes to trigger a build. - * Branch and tag names in trigger templates are interpreted as regular - * expressions. Any branch or tag change that matches that regular expression - * will trigger a build. - * Mutually exclusive with `github`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * @return \Google\Cloud\Build\V1\RepoSource|null - */ - public function getTriggerTemplate() - { - return $this->trigger_template; - } - - public function hasTriggerTemplate() - { - return isset($this->trigger_template); - } - - public function clearTriggerTemplate() - { - unset($this->trigger_template); - } - - /** - * Template describing the types of source changes to trigger a build. - * Branch and tag names in trigger templates are interpreted as regular - * expressions. Any branch or tag change that matches that regular expression - * will trigger a build. - * Mutually exclusive with `github`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * @param \Google\Cloud\Build\V1\RepoSource $var - * @return $this - */ - public function setTriggerTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\RepoSource::class); - $this->trigger_template = $var; - - return $this; - } - - /** - * GitHubEventsConfig describes the configuration of a trigger that creates - * a build whenever a GitHub event is received. - * Mutually exclusive with `trigger_template`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * @return \Google\Cloud\Build\V1\GitHubEventsConfig|null - */ - public function getGithub() - { - return $this->github; - } - - public function hasGithub() - { - return isset($this->github); - } - - public function clearGithub() - { - unset($this->github); - } - - /** - * GitHubEventsConfig describes the configuration of a trigger that creates - * a build whenever a GitHub event is received. - * Mutually exclusive with `trigger_template`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * @param \Google\Cloud\Build\V1\GitHubEventsConfig $var - * @return $this - */ - public function setGithub($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\GitHubEventsConfig::class); - $this->github = $var; - - return $this; - } - - /** - * PubsubConfig describes the configuration of a trigger that - * creates a build whenever a Pub/Sub message is published. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * @return \Google\Cloud\Build\V1\PubsubConfig|null - */ - public function getPubsubConfig() - { - return $this->pubsub_config; - } - - public function hasPubsubConfig() - { - return isset($this->pubsub_config); - } - - public function clearPubsubConfig() - { - unset($this->pubsub_config); - } - - /** - * PubsubConfig describes the configuration of a trigger that - * creates a build whenever a Pub/Sub message is published. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * @param \Google\Cloud\Build\V1\PubsubConfig $var - * @return $this - */ - public function setPubsubConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PubsubConfig::class); - $this->pubsub_config = $var; - - return $this; - } - - /** - * WebhookConfig describes the configuration of a trigger that - * creates a build whenever a webhook is sent to a trigger's webhook URL. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * @return \Google\Cloud\Build\V1\WebhookConfig|null - */ - public function getWebhookConfig() - { - return $this->webhook_config; - } - - public function hasWebhookConfig() - { - return isset($this->webhook_config); - } - - public function clearWebhookConfig() - { - unset($this->webhook_config); - } - - /** - * WebhookConfig describes the configuration of a trigger that - * creates a build whenever a webhook is sent to a trigger's webhook URL. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * @param \Google\Cloud\Build\V1\WebhookConfig $var - * @return $this - */ - public function setWebhookConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\WebhookConfig::class); - $this->webhook_config = $var; - - return $this; - } - - /** - * Autodetect build configuration. The following precedence is used (case - * insensitive): - * 1. cloudbuild.yaml - * 2. cloudbuild.yml - * 3. cloudbuild.json - * 4. Dockerfile - * Currently only available for GitHub App Triggers. - * - * Generated from protobuf field bool autodetect = 18; - * @return bool - */ - public function getAutodetect() - { - return $this->readOneof(18); - } - - public function hasAutodetect() - { - return $this->hasOneof(18); - } - - /** - * Autodetect build configuration. The following precedence is used (case - * insensitive): - * 1. cloudbuild.yaml - * 2. cloudbuild.yml - * 3. cloudbuild.json - * 4. Dockerfile - * Currently only available for GitHub App Triggers. - * - * Generated from protobuf field bool autodetect = 18; - * @param bool $var - * @return $this - */ - public function setAutodetect($var) - { - GPBUtil::checkBool($var); - $this->writeOneof(18, $var); - - return $this; - } - - /** - * Contents of the build template. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 4; - * @return \Google\Cloud\Build\V1\Build|null - */ - public function getBuild() - { - return $this->readOneof(4); - } - - public function hasBuild() - { - return $this->hasOneof(4); - } - - /** - * Contents of the build template. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 4; - * @param \Google\Cloud\Build\V1\Build $var - * @return $this - */ - public function setBuild($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Build::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Path, from the source root, to the build configuration file - * (i.e. cloudbuild.yaml). - * - * Generated from protobuf field string filename = 8; - * @return string - */ - public function getFilename() - { - return $this->readOneof(8); - } - - public function hasFilename() - { - return $this->hasOneof(8); - } - - /** - * Path, from the source root, to the build configuration file - * (i.e. cloudbuild.yaml). - * - * Generated from protobuf field string filename = 8; - * @param string $var - * @return $this - */ - public function setFilename($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Output only. Time when the trigger was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Time when the trigger was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * If true, the trigger will never automatically execute a build. - * - * Generated from protobuf field bool disabled = 9; - * @return bool - */ - public function getDisabled() - { - return $this->disabled; - } - - /** - * If true, the trigger will never automatically execute a build. - * - * Generated from protobuf field bool disabled = 9; - * @param bool $var - * @return $this - */ - public function setDisabled($var) - { - GPBUtil::checkBool($var); - $this->disabled = $var; - - return $this; - } - - /** - * Substitutions for Build resource. The keys must match the following - * regular expression: `^_[A-Z0-9_]+$`. - * - * Generated from protobuf field map substitutions = 11; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSubstitutions() - { - return $this->substitutions; - } - - /** - * Substitutions for Build resource. The keys must match the following - * regular expression: `^_[A-Z0-9_]+$`. - * - * Generated from protobuf field map substitutions = 11; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSubstitutions($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->substitutions = $arr; - - return $this; - } - - /** - * ignored_files and included_files are file glob matches using - * https://golang.org/pkg/path/filepath/#Match extended with support for "**". - * If ignored_files and changed files are both empty, then they are - * not used to determine whether or not to trigger a build. - * If ignored_files is not empty, then we ignore any files that match - * any of the ignored_file globs. If the change has no files that are - * outside of the ignored_files globs, then we do not trigger a build. - * - * Generated from protobuf field repeated string ignored_files = 15; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIgnoredFiles() - { - return $this->ignored_files; - } - - /** - * ignored_files and included_files are file glob matches using - * https://golang.org/pkg/path/filepath/#Match extended with support for "**". - * If ignored_files and changed files are both empty, then they are - * not used to determine whether or not to trigger a build. - * If ignored_files is not empty, then we ignore any files that match - * any of the ignored_file globs. If the change has no files that are - * outside of the ignored_files globs, then we do not trigger a build. - * - * Generated from protobuf field repeated string ignored_files = 15; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIgnoredFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ignored_files = $arr; - - return $this; - } - - /** - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is empty, then as far as this filter is - * concerned, we should trigger the build. - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is not empty, then we make sure that at - * least one of those files matches a included_files glob. If not, - * then we do not trigger a build. - * - * Generated from protobuf field repeated string included_files = 16; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIncludedFiles() - { - return $this->included_files; - } - - /** - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is empty, then as far as this filter is - * concerned, we should trigger the build. - * If any of the files altered in the commit pass the ignored_files - * filter and included_files is not empty, then we make sure that at - * least one of those files matches a included_files glob. If not, - * then we do not trigger a build. - * - * Generated from protobuf field repeated string included_files = 16; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIncludedFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->included_files = $arr; - - return $this; - } - - /** - * Optional. A Common Expression Language string. - * - * Generated from protobuf field string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. A Common Expression Language string. - * - * Generated from protobuf field string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The service account used for all user-controlled operations including - * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - * If no service account is set, then the standard Cloud Build service account - * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. - * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` - * - * Generated from protobuf field string service_account = 33 [(.google.api.resource_reference) = { - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * The service account used for all user-controlled operations including - * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - * If no service account is set, then the standard Cloud Build service account - * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. - * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` - * - * Generated from protobuf field string service_account = 33 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * @return string - */ - public function getBuildTemplate() - { - return $this->whichOneof("build_template"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_FailureInfo.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_FailureInfo.php deleted file mode 100644 index 92e05d0c389f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Build_FailureInfo.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.BuiltImage - */ -class BuiltImage extends \Google\Protobuf\Internal\Message -{ - /** - * Name used to push the container image to Google Container Registry, as - * presented to `docker push`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Docker Registry 2.0 digest. - * - * Generated from protobuf field string digest = 3; - */ - protected $digest = ''; - /** - * Output only. Stores timing information for pushing the specified image. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $push_timing = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name used to push the container image to Google Container Registry, as - * presented to `docker push`. - * @type string $digest - * Docker Registry 2.0 digest. - * @type \Google\Cloud\Build\V1\TimeSpan $push_timing - * Output only. Stores timing information for pushing the specified image. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Name used to push the container image to Google Container Registry, as - * presented to `docker push`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name used to push the container image to Google Container Registry, as - * presented to `docker push`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Docker Registry 2.0 digest. - * - * Generated from protobuf field string digest = 3; - * @return string - */ - public function getDigest() - { - return $this->digest; - } - - /** - * Docker Registry 2.0 digest. - * - * Generated from protobuf field string digest = 3; - * @param string $var - * @return $this - */ - public function setDigest($var) - { - GPBUtil::checkString($var, True); - $this->digest = $var; - - return $this; - } - - /** - * Output only. Stores timing information for pushing the specified image. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getPushTiming() - { - return $this->push_timing; - } - - public function hasPushTiming() - { - return isset($this->push_timing); - } - - public function clearPushTiming() - { - unset($this->push_timing); - } - - /** - * Output only. Stores timing information for pushing the specified image. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setPushTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->push_timing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CancelBuildRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CancelBuildRequest.php deleted file mode 100644 index 2c3acff597ce..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CancelBuildRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v1.CancelBuildRequest - */ -class CancelBuildRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Build` to cancel. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Build` to cancel. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type string $project_id - * Required. ID of the project. - * @type string $id - * Required. ID of the build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Build` to cancel. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Build` to cancel. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CloudBuildGrpcClient.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CloudBuildGrpcClient.php deleted file mode 100644 index 25ca618e4778..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CloudBuildGrpcClient.php +++ /dev/null @@ -1,364 +0,0 @@ -_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/CreateBuild', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Returns information about a previously requested build. - * - * The `Build` that is returned includes its status (such as `SUCCESS`, - * `FAILURE`, or `WORKING`), and timing information. - * @param \Google\Cloud\Build\V1\GetBuildRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetBuild(\Google\Cloud\Build\V1\GetBuildRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/GetBuild', - $argument, - ['\Google\Cloud\Build\V1\Build', 'decode'], - $metadata, $options); - } - - /** - * Lists previously requested builds. - * - * Previously requested builds may still be in-progress, or may have finished - * successfully or unsuccessfully. - * @param \Google\Cloud\Build\V1\ListBuildsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListBuilds(\Google\Cloud\Build\V1\ListBuildsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/ListBuilds', - $argument, - ['\Google\Cloud\Build\V1\ListBuildsResponse', 'decode'], - $metadata, $options); - } - - /** - * Cancels a build in progress. - * @param \Google\Cloud\Build\V1\CancelBuildRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CancelBuild(\Google\Cloud\Build\V1\CancelBuildRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/CancelBuild', - $argument, - ['\Google\Cloud\Build\V1\Build', 'decode'], - $metadata, $options); - } - - /** - * Creates a new build based on the specified build. - * - * This method creates a new build using the original build request, which may - * or may not result in an identical build. - * - * For triggered builds: - * - * * Triggered builds resolve to a precise revision; therefore a retry of a - * triggered build will result in a build that uses the same revision. - * - * For non-triggered builds that specify `RepoSource`: - * - * * If the original build built from the tip of a branch, the retried build - * will build from the tip of that branch, which may not be the same revision - * as the original build. - * * If the original build specified a commit sha or revision ID, the retried - * build will use the identical source. - * - * For builds that specify `StorageSource`: - * - * * If the original build pulled source from Google Cloud Storage without - * specifying the generation of the object, the new build will use the current - * object, which may be different from the original build source. - * * If the original build pulled source from Cloud Storage and specified the - * generation of the object, the new build will attempt to use the same - * object, which may or may not be available depending on the bucket's - * lifecycle management settings. - * @param \Google\Cloud\Build\V1\RetryBuildRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RetryBuild(\Google\Cloud\Build\V1\RetryBuildRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/RetryBuild', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Approves or rejects a pending build. - * - * If approved, the returned LRO will be analogous to the LRO returned from - * a CreateBuild call. - * - * If rejected, the returned LRO will be immediately done. - * @param \Google\Cloud\Build\V1\ApproveBuildRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ApproveBuild(\Google\Cloud\Build\V1\ApproveBuildRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/ApproveBuild', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Creates a new `BuildTrigger`. - * - * This API is experimental. - * @param \Google\Cloud\Build\V1\CreateBuildTriggerRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateBuildTrigger(\Google\Cloud\Build\V1\CreateBuildTriggerRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/CreateBuildTrigger', - $argument, - ['\Google\Cloud\Build\V1\BuildTrigger', 'decode'], - $metadata, $options); - } - - /** - * Returns information about a `BuildTrigger`. - * - * This API is experimental. - * @param \Google\Cloud\Build\V1\GetBuildTriggerRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetBuildTrigger(\Google\Cloud\Build\V1\GetBuildTriggerRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/GetBuildTrigger', - $argument, - ['\Google\Cloud\Build\V1\BuildTrigger', 'decode'], - $metadata, $options); - } - - /** - * Lists existing `BuildTrigger`s. - * - * This API is experimental. - * @param \Google\Cloud\Build\V1\ListBuildTriggersRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListBuildTriggers(\Google\Cloud\Build\V1\ListBuildTriggersRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/ListBuildTriggers', - $argument, - ['\Google\Cloud\Build\V1\ListBuildTriggersResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes a `BuildTrigger` by its project ID and trigger ID. - * - * This API is experimental. - * @param \Google\Cloud\Build\V1\DeleteBuildTriggerRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteBuildTrigger(\Google\Cloud\Build\V1\DeleteBuildTriggerRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/DeleteBuildTrigger', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Updates a `BuildTrigger` by its project ID and trigger ID. - * - * This API is experimental. - * @param \Google\Cloud\Build\V1\UpdateBuildTriggerRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateBuildTrigger(\Google\Cloud\Build\V1\UpdateBuildTriggerRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/UpdateBuildTrigger', - $argument, - ['\Google\Cloud\Build\V1\BuildTrigger', 'decode'], - $metadata, $options); - } - - /** - * Runs a `BuildTrigger` at a particular source revision. - * @param \Google\Cloud\Build\V1\RunBuildTriggerRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RunBuildTrigger(\Google\Cloud\Build\V1\RunBuildTriggerRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/RunBuildTrigger', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * ReceiveTriggerWebhook [Experimental] is called when the API receives a - * webhook request targeted at a specific trigger. - * @param \Google\Cloud\Build\V1\ReceiveTriggerWebhookRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ReceiveTriggerWebhook(\Google\Cloud\Build\V1\ReceiveTriggerWebhookRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/ReceiveTriggerWebhook', - $argument, - ['\Google\Cloud\Build\V1\ReceiveTriggerWebhookResponse', 'decode'], - $metadata, $options); - } - - /** - * Creates a `WorkerPool`. - * @param \Google\Cloud\Build\V1\CreateWorkerPoolRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateWorkerPool(\Google\Cloud\Build\V1\CreateWorkerPoolRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/CreateWorkerPool', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Returns details of a `WorkerPool`. - * @param \Google\Cloud\Build\V1\GetWorkerPoolRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetWorkerPool(\Google\Cloud\Build\V1\GetWorkerPoolRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/GetWorkerPool', - $argument, - ['\Google\Cloud\Build\V1\WorkerPool', 'decode'], - $metadata, $options); - } - - /** - * Deletes a `WorkerPool`. - * @param \Google\Cloud\Build\V1\DeleteWorkerPoolRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteWorkerPool(\Google\Cloud\Build\V1\DeleteWorkerPoolRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/DeleteWorkerPool', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a `WorkerPool`. - * @param \Google\Cloud\Build\V1\UpdateWorkerPoolRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateWorkerPool(\Google\Cloud\Build\V1\UpdateWorkerPoolRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/UpdateWorkerPool', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists `WorkerPool`s. - * @param \Google\Cloud\Build\V1\ListWorkerPoolsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListWorkerPools(\Google\Cloud\Build\V1\ListWorkerPoolsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v1.CloudBuild/ListWorkerPools', - $argument, - ['\Google\Cloud\Build\V1\ListWorkerPoolsResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildRequest.php deleted file mode 100644 index 4208acd985dd..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.devtools.cloudbuild.v1.CreateBuildRequest - */ -class CreateBuildRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The parent resource where this build will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. Build resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $build = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The parent resource where this build will be created. - * Format: `projects/{project}/locations/{location}` - * @type string $project_id - * Required. ID of the project. - * @type \Google\Cloud\Build\V1\Build $build - * Required. Build resource to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The parent resource where this build will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The parent resource where this build will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. Build resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V1\Build|null - */ - public function getBuild() - { - return $this->build; - } - - public function hasBuild() - { - return isset($this->build); - } - - public function clearBuild() - { - unset($this->build); - } - - /** - * Required. Build resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V1\Build $var - * @return $this - */ - public function setBuild($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\Build::class); - $this->build = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildTriggerRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildTriggerRequest.php deleted file mode 100644 index 18955fea41ba..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateBuildTriggerRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.devtools.cloudbuild.v1.CreateBuildTriggerRequest - */ -class CreateBuildTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The parent resource where this trigger will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 3 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. ID of the project for which to configure automatic builds. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. `BuildTrigger` to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The parent resource where this trigger will be created. - * Format: `projects/{project}/locations/{location}` - * @type string $project_id - * Required. ID of the project for which to configure automatic builds. - * @type \Google\Cloud\Build\V1\BuildTrigger $trigger - * Required. `BuildTrigger` to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The parent resource where this trigger will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The parent resource where this trigger will be created. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. ID of the project for which to configure automatic builds. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project for which to configure automatic builds. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. `BuildTrigger` to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V1\BuildTrigger|null - */ - public function getTrigger() - { - return $this->trigger; - } - - public function hasTrigger() - { - return isset($this->trigger); - } - - public function clearTrigger() - { - unset($this->trigger); - } - - /** - * Required. `BuildTrigger` to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V1\BuildTrigger $var - * @return $this - */ - public function setTrigger($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\BuildTrigger::class); - $this->trigger = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolOperationMetadata.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolOperationMetadata.php deleted file mode 100644 index 6ae51441e432..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolOperationMetadata.php +++ /dev/null @@ -1,163 +0,0 @@ -google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata - */ -class CreateWorkerPoolOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the `WorkerPool` to create. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - */ - protected $worker_pool = ''; - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - */ - protected $complete_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $worker_pool - * The resource name of the `WorkerPool` to create. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * @type \Google\Protobuf\Timestamp $create_time - * Time the operation was created. - * @type \Google\Protobuf\Timestamp $complete_time - * Time the operation was completed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the `WorkerPool` to create. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getWorkerPool() - { - return $this->worker_pool; - } - - /** - * The resource name of the `WorkerPool` to create. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setWorkerPool($var) - { - GPBUtil::checkString($var, True); - $this->worker_pool = $var; - - return $this; - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCompleteTime() - { - return $this->complete_time; - } - - public function hasCompleteTime() - { - return isset($this->complete_time); - } - - public function clearCompleteTime() - { - unset($this->complete_time); - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCompleteTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->complete_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolRequest.php deleted file mode 100644 index 54d740317479..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/CreateWorkerPoolRequest.php +++ /dev/null @@ -1,199 +0,0 @@ -google.devtools.cloudbuild.v1.CreateWorkerPoolRequest - */ -class CreateWorkerPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource where this worker pool will be created. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. `WorkerPool` resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $worker_pool = null; - /** - * Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - */ - protected $worker_pool_id = ''; - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource where this worker pool will be created. - * Format: `projects/{project}/locations/{location}`. - * @type \Google\Cloud\Build\V1\WorkerPool $worker_pool - * Required. `WorkerPool` resource to create. - * @type string $worker_pool_id - * Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * @type bool $validate_only - * If set, validate the request and preview the response, but do not actually - * post it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource where this worker pool will be created. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource where this worker pool will be created. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. `WorkerPool` resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V1\WorkerPool|null - */ - public function getWorkerPool() - { - return $this->worker_pool; - } - - public function hasWorkerPool() - { - return isset($this->worker_pool); - } - - public function clearWorkerPool() - { - unset($this->worker_pool); - } - - /** - * Required. `WorkerPool` resource to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V1\WorkerPool $var - * @return $this - */ - public function setWorkerPool($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\WorkerPool::class); - $this->worker_pool = $var; - - return $this; - } - - /** - * Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getWorkerPoolId() - { - return $this->worker_pool_id; - } - - /** - * Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setWorkerPoolId($var) - { - GPBUtil::checkString($var, True); - $this->worker_pool_id = $var; - - return $this; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteBuildTriggerRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteBuildTriggerRequest.php deleted file mode 100644 index 62f2f7945674..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteBuildTriggerRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest - */ -class DeleteBuildTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Trigger` to delete. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. ID of the `BuildTrigger` to delete. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Trigger` to delete. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type string $project_id - * Required. ID of the project that owns the trigger. - * @type string $trigger_id - * Required. ID of the `BuildTrigger` to delete. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Trigger` to delete. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Trigger` to delete. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. ID of the `BuildTrigger` to delete. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * Required. ID of the `BuildTrigger` to delete. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolOperationMetadata.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolOperationMetadata.php deleted file mode 100644 index 3b0551316dde..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolOperationMetadata.php +++ /dev/null @@ -1,163 +0,0 @@ -google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata - */ -class DeleteWorkerPoolOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the `WorkerPool` being deleted. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - */ - protected $worker_pool = ''; - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - */ - protected $complete_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $worker_pool - * The resource name of the `WorkerPool` being deleted. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * @type \Google\Protobuf\Timestamp $create_time - * Time the operation was created. - * @type \Google\Protobuf\Timestamp $complete_time - * Time the operation was completed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the `WorkerPool` being deleted. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getWorkerPool() - { - return $this->worker_pool; - } - - /** - * The resource name of the `WorkerPool` being deleted. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setWorkerPool($var) - { - GPBUtil::checkString($var, True); - $this->worker_pool = $var; - - return $this; - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCompleteTime() - { - return $this->complete_time; - } - - public function hasCompleteTime() - { - return isset($this->complete_time); - } - - public function clearCompleteTime() - { - unset($this->complete_time); - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCompleteTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->complete_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolRequest.php deleted file mode 100644 index 2c84b18eea0e..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/DeleteWorkerPoolRequest.php +++ /dev/null @@ -1,189 +0,0 @@ -google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest - */ -class DeleteWorkerPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the `WorkerPool` to delete. - * Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. If this is provided, it must match the server's etag on the - * workerpool for the request to be processed. - * - * Generated from protobuf field string etag = 2; - */ - protected $etag = ''; - /** - * If set to true, and the `WorkerPool` is not found, the request will succeed - * but no action will be taken on the server. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the `WorkerPool` to delete. - * Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @type string $etag - * Optional. If this is provided, it must match the server's etag on the - * workerpool for the request to be processed. - * @type bool $allow_missing - * If set to true, and the `WorkerPool` is not found, the request will succeed - * but no action will be taken on the server. - * @type bool $validate_only - * If set, validate the request and preview the response, but do not actually - * post it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the `WorkerPool` to delete. - * Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the `WorkerPool` to delete. - * Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. If this is provided, it must match the server's etag on the - * workerpool for the request to be processed. - * - * Generated from protobuf field string etag = 2; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Optional. If this is provided, it must match the server's etag on the - * workerpool for the request to be processed. - * - * Generated from protobuf field string etag = 2; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * If set to true, and the `WorkerPool` is not found, the request will succeed - * but no action will be taken on the server. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the `WorkerPool` is not found, the request will succeed - * but no action will be taken on the server. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/FileHashes.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/FileHashes.php deleted file mode 100644 index 044ed6721551..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/FileHashes.php +++ /dev/null @@ -1,68 +0,0 @@ -google.devtools.cloudbuild.v1.FileHashes - */ -class FileHashes extends \Google\Protobuf\Internal\Message -{ - /** - * Collection of file hashes. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - private $file_hash; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $file_hash - * Collection of file hashes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Collection of file hashes. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFileHash() - { - return $this->file_hash; - } - - /** - * Collection of file hashes. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - * @param array<\Google\Cloud\Build\V1\Hash>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFileHash($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Hash::class); - $this->file_hash = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildRequest.php deleted file mode 100644 index 8b42bcb8ba94..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v1.GetBuildRequest - */ -class GetBuildRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Build` to retrieve. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Build` to retrieve. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type string $project_id - * Required. ID of the project. - * @type string $id - * Required. ID of the build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Build` to retrieve. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Build` to retrieve. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Required. ID of the build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildTriggerRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildTriggerRequest.php deleted file mode 100644 index 53e62c5cf325..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetBuildTriggerRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v1.GetBuildTriggerRequest - */ -class GetBuildTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Trigger` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Trigger` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type string $project_id - * Required. ID of the project that owns the trigger. - * @type string $trigger_id - * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Trigger` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Trigger` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetWorkerPoolRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetWorkerPoolRequest.php deleted file mode 100644 index 2f6ae188ce45..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GetWorkerPoolRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.devtools.cloudbuild.v1.GetWorkerPoolRequest - */ -class GetWorkerPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the `WorkerPool` to retrieve. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the `WorkerPool` to retrieve. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the `WorkerPool` to retrieve. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the `WorkerPool` to retrieve. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitHubEventsConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitHubEventsConfig.php deleted file mode 100644 index 1f5624b04757..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitHubEventsConfig.php +++ /dev/null @@ -1,229 +0,0 @@ -google.devtools.cloudbuild.v1.GitHubEventsConfig - */ -class GitHubEventsConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The installationID that emits the GitHub event. - * - * Generated from protobuf field int64 installation_id = 1 [deprecated = true]; - * @deprecated - */ - protected $installation_id = 0; - /** - * Owner of the repository. For example: The owner for - * https://github.com/googlecloudplatform/cloud-builders is - * "googlecloudplatform". - * - * Generated from protobuf field string owner = 6; - */ - protected $owner = ''; - /** - * Name of the repository. For example: The name for - * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders". - * - * Generated from protobuf field string name = 7; - */ - protected $name = ''; - protected $event; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $installation_id - * The installationID that emits the GitHub event. - * @type string $owner - * Owner of the repository. For example: The owner for - * https://github.com/googlecloudplatform/cloud-builders is - * "googlecloudplatform". - * @type string $name - * Name of the repository. For example: The name for - * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders". - * @type \Google\Cloud\Build\V1\PullRequestFilter $pull_request - * filter to match changes in pull requests. - * @type \Google\Cloud\Build\V1\PushFilter $push - * filter to match changes in refs like branches, tags. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The installationID that emits the GitHub event. - * - * Generated from protobuf field int64 installation_id = 1 [deprecated = true]; - * @return int|string - * @deprecated - */ - public function getInstallationId() - { - @trigger_error('installation_id is deprecated.', E_USER_DEPRECATED); - return $this->installation_id; - } - - /** - * The installationID that emits the GitHub event. - * - * Generated from protobuf field int64 installation_id = 1 [deprecated = true]; - * @param int|string $var - * @return $this - * @deprecated - */ - public function setInstallationId($var) - { - @trigger_error('installation_id is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkInt64($var); - $this->installation_id = $var; - - return $this; - } - - /** - * Owner of the repository. For example: The owner for - * https://github.com/googlecloudplatform/cloud-builders is - * "googlecloudplatform". - * - * Generated from protobuf field string owner = 6; - * @return string - */ - public function getOwner() - { - return $this->owner; - } - - /** - * Owner of the repository. For example: The owner for - * https://github.com/googlecloudplatform/cloud-builders is - * "googlecloudplatform". - * - * Generated from protobuf field string owner = 6; - * @param string $var - * @return $this - */ - public function setOwner($var) - { - GPBUtil::checkString($var, True); - $this->owner = $var; - - return $this; - } - - /** - * Name of the repository. For example: The name for - * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders". - * - * Generated from protobuf field string name = 7; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the repository. For example: The name for - * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders". - * - * Generated from protobuf field string name = 7; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * filter to match changes in pull requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * @return \Google\Cloud\Build\V1\PullRequestFilter|null - */ - public function getPullRequest() - { - return $this->readOneof(4); - } - - public function hasPullRequest() - { - return $this->hasOneof(4); - } - - /** - * filter to match changes in pull requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * @param \Google\Cloud\Build\V1\PullRequestFilter $var - * @return $this - */ - public function setPullRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PullRequestFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * filter to match changes in refs like branches, tags. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PushFilter push = 5; - * @return \Google\Cloud\Build\V1\PushFilter|null - */ - public function getPush() - { - return $this->readOneof(5); - } - - public function hasPush() - { - return $this->hasOneof(5); - } - - /** - * filter to match changes in refs like branches, tags. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PushFilter push = 5; - * @param \Google\Cloud\Build\V1\PushFilter $var - * @return $this - */ - public function setPush($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PushFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getEvent() - { - return $this->whichOneof("event"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitSource.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitSource.php deleted file mode 100644 index 9905718317d7..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/GitSource.php +++ /dev/null @@ -1,179 +0,0 @@ -google.devtools.cloudbuild.v1.GitSource - */ -class GitSource extends \Google\Protobuf\Internal\Message -{ - /** - * Location of the Git repo to build. - * This will be used as a `git remote`, see - * https://git-scm.com/docs/git-remote. - * - * Generated from protobuf field string url = 1; - */ - protected $url = ''; - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 5; - */ - protected $dir = ''; - /** - * The revision to fetch from the Git repository such as a branch, a tag, a - * commit SHA, or any Git ref. - * Cloud Build uses `git fetch` to fetch the revision from the Git - * repository; therefore make sure that the string you provide for `revision` - * is parsable by the command. For information on string values accepted by - * `git fetch`, see - * https://git-scm.com/docs/gitrevisions#_specifying_revisions. For - * information on `git fetch`, see https://git-scm.com/docs/git-fetch. - * - * Generated from protobuf field string revision = 6; - */ - protected $revision = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $url - * Location of the Git repo to build. - * This will be used as a `git remote`, see - * https://git-scm.com/docs/git-remote. - * @type string $dir - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * @type string $revision - * The revision to fetch from the Git repository such as a branch, a tag, a - * commit SHA, or any Git ref. - * Cloud Build uses `git fetch` to fetch the revision from the Git - * repository; therefore make sure that the string you provide for `revision` - * is parsable by the command. For information on string values accepted by - * `git fetch`, see - * https://git-scm.com/docs/gitrevisions#_specifying_revisions. For - * information on `git fetch`, see https://git-scm.com/docs/git-fetch. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Location of the Git repo to build. - * This will be used as a `git remote`, see - * https://git-scm.com/docs/git-remote. - * - * Generated from protobuf field string url = 1; - * @return string - */ - public function getUrl() - { - return $this->url; - } - - /** - * Location of the Git repo to build. - * This will be used as a `git remote`, see - * https://git-scm.com/docs/git-remote. - * - * Generated from protobuf field string url = 1; - * @param string $var - * @return $this - */ - public function setUrl($var) - { - GPBUtil::checkString($var, True); - $this->url = $var; - - return $this; - } - - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 5; - * @return string - */ - public function getDir() - { - return $this->dir; - } - - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 5; - * @param string $var - * @return $this - */ - public function setDir($var) - { - GPBUtil::checkString($var, True); - $this->dir = $var; - - return $this; - } - - /** - * The revision to fetch from the Git repository such as a branch, a tag, a - * commit SHA, or any Git ref. - * Cloud Build uses `git fetch` to fetch the revision from the Git - * repository; therefore make sure that the string you provide for `revision` - * is parsable by the command. For information on string values accepted by - * `git fetch`, see - * https://git-scm.com/docs/gitrevisions#_specifying_revisions. For - * information on `git fetch`, see https://git-scm.com/docs/git-fetch. - * - * Generated from protobuf field string revision = 6; - * @return string - */ - public function getRevision() - { - return $this->revision; - } - - /** - * The revision to fetch from the Git repository such as a branch, a tag, a - * commit SHA, or any Git ref. - * Cloud Build uses `git fetch` to fetch the revision from the Git - * repository; therefore make sure that the string you provide for `revision` - * is parsable by the command. For information on string values accepted by - * `git fetch`, see - * https://git-scm.com/docs/gitrevisions#_specifying_revisions. For - * information on `git fetch`, see https://git-scm.com/docs/git-fetch. - * - * Generated from protobuf field string revision = 6; - * @param string $var - * @return $this - */ - public function setRevision($var) - { - GPBUtil::checkString($var, True); - $this->revision = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash.php deleted file mode 100644 index 31a0f1ee0c10..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash.php +++ /dev/null @@ -1,101 +0,0 @@ -google.devtools.cloudbuild.v1.Hash - */ -class Hash extends \Google\Protobuf\Internal\Message -{ - /** - * The type of hash that was performed. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - */ - protected $type = 0; - /** - * The hash value. - * - * Generated from protobuf field bytes value = 2; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The type of hash that was performed. - * @type string $value - * The hash value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The type of hash that was performed. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of hash that was performed. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\Hash\HashType::class); - $this->type = $var; - - return $this; - } - - /** - * The hash value. - * - * Generated from protobuf field bytes value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The hash value. - * - * Generated from protobuf field bytes value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, False); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash/HashType.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash/HashType.php deleted file mode 100644 index 42fde7ccdc73..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash/HashType.php +++ /dev/null @@ -1,71 +0,0 @@ -google.devtools.cloudbuild.v1.Hash.HashType - */ -class HashType -{ - /** - * No hash requested. - * - * Generated from protobuf enum NONE = 0; - */ - const NONE = 0; - /** - * Use a sha256 hash. - * - * Generated from protobuf enum SHA256 = 1; - */ - const SHA256 = 1; - /** - * Use a md5 hash. - * - * Generated from protobuf enum MD5 = 2; - */ - const MD5 = 2; - /** - * Use a sha512 hash. - * - * Generated from protobuf enum SHA512 = 4; - */ - const SHA512 = 4; - - private static $valueToName = [ - self::NONE => 'NONE', - self::SHA256 => 'SHA256', - self::MD5 => 'MD5', - self::SHA512 => 'SHA512', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(HashType::class, \Google\Cloud\Build\V1\Hash_HashType::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash_HashType.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash_HashType.php deleted file mode 100644 index 601a59a11406..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Hash_HashType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.InlineSecret - */ -class InlineSecret extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of Cloud KMS crypto key to decrypt the encrypted value. - * In format: projects/*/locations/*/keyRings/*/cryptoKeys/* - * - * Generated from protobuf field string kms_key_name = 1 [(.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map env_map = 2; - */ - private $env_map; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $kms_key_name - * Resource name of Cloud KMS crypto key to decrypt the encrypted value. - * In format: projects/*/locations/*/keyRings/*/cryptoKeys/* - * @type array|\Google\Protobuf\Internal\MapField $env_map - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of Cloud KMS crypto key to decrypt the encrypted value. - * In format: projects/*/locations/*/keyRings/*/cryptoKeys/* - * - * Generated from protobuf field string kms_key_name = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Resource name of Cloud KMS crypto key to decrypt the encrypted value. - * In format: projects/*/locations/*/keyRings/*/cryptoKeys/* - * - * Generated from protobuf field string kms_key_name = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map env_map = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getEnvMap() - { - return $this->env_map; - } - - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map env_map = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setEnvMap($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::BYTES); - $this->env_map = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersRequest.php deleted file mode 100644 index 58aad9b9af31..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersRequest.php +++ /dev/null @@ -1,173 +0,0 @@ -google.devtools.cloudbuild.v1.ListBuildTriggersRequest - */ -class ListBuildTriggersRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The parent of the collection of `Triggers`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. ID of the project for which to list BuildTriggers. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The parent of the collection of `Triggers`. - * Format: `projects/{project}/locations/{location}` - * @type string $project_id - * Required. ID of the project for which to list BuildTriggers. - * @type int $page_size - * Number of results to return in the list. - * @type string $page_token - * Token to provide to skip to a particular spot in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The parent of the collection of `Triggers`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The parent of the collection of `Triggers`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. ID of the project for which to list BuildTriggers. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project for which to list BuildTriggers. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Token to provide to skip to a particular spot in the list. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersResponse.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersResponse.php deleted file mode 100644 index 19157ac51bf5..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildTriggersResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.devtools.cloudbuild.v1.ListBuildTriggersResponse - */ -class ListBuildTriggersResponse extends \Google\Protobuf\Internal\Message -{ - /** - * `BuildTriggers` for the project, sorted by `create_time` descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - private $triggers; - /** - * Token to receive the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\BuildTrigger>|\Google\Protobuf\Internal\RepeatedField $triggers - * `BuildTriggers` for the project, sorted by `create_time` descending. - * @type string $next_page_token - * Token to receive the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * `BuildTriggers` for the project, sorted by `create_time` descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTriggers() - { - return $this->triggers; - } - - /** - * `BuildTriggers` for the project, sorted by `create_time` descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - * @param array<\Google\Cloud\Build\V1\BuildTrigger>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTriggers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\BuildTrigger::class); - $this->triggers = $arr; - - return $this; - } - - /** - * Token to receive the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to receive the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsRequest.php deleted file mode 100644 index 1e52c03b6cd9..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsRequest.php +++ /dev/null @@ -1,227 +0,0 @@ -google.devtools.cloudbuild.v1.ListBuildsRequest - */ -class ListBuildsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The parent of the collection of `Builds`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 9 [(.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token for the next page of Builds. - * If unspecified, the first page of results is returned. - * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown. - * In this case, the token should be discarded, and pagination should be - * restarted from the first page of results. - * See https://google.aip.dev/158 for more. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * The raw filter text to constrain the results. - * - * Generated from protobuf field string filter = 8; - */ - protected $filter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * The parent of the collection of `Builds`. - * Format: `projects/{project}/locations/{location}` - * @type string $project_id - * Required. ID of the project. - * @type int $page_size - * Number of results to return in the list. - * @type string $page_token - * The page token for the next page of Builds. - * If unspecified, the first page of results is returned. - * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown. - * In this case, the token should be discarded, and pagination should be - * restarted from the first page of results. - * See https://google.aip.dev/158 for more. - * @type string $filter - * The raw filter text to constrain the results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The parent of the collection of `Builds`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 9 [(.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The parent of the collection of `Builds`. - * Format: `projects/{project}/locations/{location}` - * - * Generated from protobuf field string parent = 9 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token for the next page of Builds. - * If unspecified, the first page of results is returned. - * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown. - * In this case, the token should be discarded, and pagination should be - * restarted from the first page of results. - * See https://google.aip.dev/158 for more. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token for the next page of Builds. - * If unspecified, the first page of results is returned. - * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown. - * In this case, the token should be discarded, and pagination should be - * restarted from the first page of results. - * See https://google.aip.dev/158 for more. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The raw filter text to constrain the results. - * - * Generated from protobuf field string filter = 8; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The raw filter text to constrain the results. - * - * Generated from protobuf field string filter = 8; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsResponse.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsResponse.php deleted file mode 100644 index 875057f01c94..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListBuildsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.devtools.cloudbuild.v1.ListBuildsResponse - */ -class ListBuildsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Builds will be sorted by `create_time`, descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - private $builds; - /** - * Token to receive the next page of results. - * This will be absent if the end of the response list has been reached. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\Build>|\Google\Protobuf\Internal\RepeatedField $builds - * Builds will be sorted by `create_time`, descending. - * @type string $next_page_token - * Token to receive the next page of results. - * This will be absent if the end of the response list has been reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Builds will be sorted by `create_time`, descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build builds = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBuilds() - { - return $this->builds; - } - - /** - * Builds will be sorted by `create_time`, descending. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.Build builds = 1; - * @param array<\Google\Cloud\Build\V1\Build>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBuilds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\Build::class); - $this->builds = $arr; - - return $this; - } - - /** - * Token to receive the next page of results. - * This will be absent if the end of the response list has been reached. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to receive the next page of results. - * This will be absent if the end of the response list has been reached. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsRequest.php deleted file mode 100644 index 72bd53d2d4d2..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsRequest.php +++ /dev/null @@ -1,147 +0,0 @@ -google.devtools.cloudbuild.v1.ListWorkerPoolsRequest - */ -class ListWorkerPoolsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent of the collection of `WorkerPools`. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of `WorkerPool`s to return. The service may return - * fewer than this value. If omitted, the server will use a sensible default. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListWorkerPools` call. Provide this - * to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent of the collection of `WorkerPools`. - * Format: `projects/{project}/locations/{location}`. - * @type int $page_size - * The maximum number of `WorkerPool`s to return. The service may return - * fewer than this value. If omitted, the server will use a sensible default. - * @type string $page_token - * A page token, received from a previous `ListWorkerPools` call. Provide this - * to retrieve the subsequent page. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent of the collection of `WorkerPools`. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent of the collection of `WorkerPools`. - * Format: `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of `WorkerPool`s to return. The service may return - * fewer than this value. If omitted, the server will use a sensible default. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of `WorkerPool`s to return. The service may return - * fewer than this value. If omitted, the server will use a sensible default. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListWorkerPools` call. Provide this - * to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListWorkerPools` call. Provide this - * to retrieve the subsequent page. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsResponse.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsResponse.php deleted file mode 100644 index 7c91d42c7083..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ListWorkerPoolsResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.devtools.cloudbuild.v1.ListWorkerPoolsResponse - */ -class ListWorkerPoolsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * `WorkerPools` for the specified project. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - private $worker_pools; - /** - * Continuation token used to page through large result sets. Provide this - * value in a subsequent ListWorkerPoolsRequest to return the next page of - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\WorkerPool>|\Google\Protobuf\Internal\RepeatedField $worker_pools - * `WorkerPools` for the specified project. - * @type string $next_page_token - * Continuation token used to page through large result sets. Provide this - * value in a subsequent ListWorkerPoolsRequest to return the next page of - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * `WorkerPools` for the specified project. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getWorkerPools() - { - return $this->worker_pools; - } - - /** - * `WorkerPools` for the specified project. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - * @param array<\Google\Cloud\Build\V1\WorkerPool>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setWorkerPools($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\WorkerPool::class); - $this->worker_pools = $arr; - - return $this; - } - - /** - * Continuation token used to page through large result sets. Provide this - * value in a subsequent ListWorkerPoolsRequest to return the next page of - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Continuation token used to page through large result sets. Provide this - * value in a subsequent ListWorkerPoolsRequest to return the next page of - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config.php deleted file mode 100644 index 2a3d1086320f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config.php +++ /dev/null @@ -1,121 +0,0 @@ -google.devtools.cloudbuild.v1.PrivatePoolV1Config - */ -class PrivatePoolV1Config extends \Google\Protobuf\Internal\Message -{ - /** - * Machine configuration for the workers in the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - */ - protected $worker_config = null; - /** - * Network configuration for the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - */ - protected $network_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V1\PrivatePoolV1Config\WorkerConfig $worker_config - * Machine configuration for the workers in the pool. - * @type \Google\Cloud\Build\V1\PrivatePoolV1Config\NetworkConfig $network_config - * Network configuration for the pool. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Machine configuration for the workers in the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * @return \Google\Cloud\Build\V1\PrivatePoolV1Config\WorkerConfig|null - */ - public function getWorkerConfig() - { - return $this->worker_config; - } - - public function hasWorkerConfig() - { - return isset($this->worker_config); - } - - public function clearWorkerConfig() - { - unset($this->worker_config); - } - - /** - * Machine configuration for the workers in the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * @param \Google\Cloud\Build\V1\PrivatePoolV1Config\WorkerConfig $var - * @return $this - */ - public function setWorkerConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PrivatePoolV1Config\WorkerConfig::class); - $this->worker_config = $var; - - return $this; - } - - /** - * Network configuration for the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * @return \Google\Cloud\Build\V1\PrivatePoolV1Config\NetworkConfig|null - */ - public function getNetworkConfig() - { - return $this->network_config; - } - - public function hasNetworkConfig() - { - return isset($this->network_config); - } - - public function clearNetworkConfig() - { - unset($this->network_config); - } - - /** - * Network configuration for the pool. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * @param \Google\Cloud\Build\V1\PrivatePoolV1Config\NetworkConfig $var - * @return $this - */ - public function setNetworkConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PrivatePoolV1Config\NetworkConfig::class); - $this->network_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig.php deleted file mode 100644 index ae9925e16049..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig.php +++ /dev/null @@ -1,194 +0,0 @@ -google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig - */ -class NetworkConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Immutable. The network definition that the workers are peered - * to. If this section is left empty, the workers will be peered to - * `WorkerPool.project_id` on the service producer network. Must be in the - * format `projects/{project}/global/networks/{network}`, where `{project}` - * is a project number, such as `12345`, and `{network}` is the name of a - * VPC network in the project. See - * [Understanding network configuration - * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment) - * - * Generated from protobuf field string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $peered_network = ''; - /** - * Option to configure network egress for the workers. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - */ - protected $egress_option = 0; - /** - * Immutable. Subnet IP range within the peered network. This is specified - * in CIDR notation with a slash and the subnet prefix size. You can - * optionally specify an IP address before the subnet prefix value. e.g. - * `192.168.0.0/29` would specify an IP range starting at 192.168.0.0 with a - * prefix size of 29 bits. - * `/16` would specify a prefix size of 16 bits, with an automatically - * determined IP within the peered VPC. - * If unspecified, a value of `/24` will be used. - * - * Generated from protobuf field string peered_network_ip_range = 3 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $peered_network_ip_range = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $peered_network - * Required. Immutable. The network definition that the workers are peered - * to. If this section is left empty, the workers will be peered to - * `WorkerPool.project_id` on the service producer network. Must be in the - * format `projects/{project}/global/networks/{network}`, where `{project}` - * is a project number, such as `12345`, and `{network}` is the name of a - * VPC network in the project. See - * [Understanding network configuration - * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment) - * @type int $egress_option - * Option to configure network egress for the workers. - * @type string $peered_network_ip_range - * Immutable. Subnet IP range within the peered network. This is specified - * in CIDR notation with a slash and the subnet prefix size. You can - * optionally specify an IP address before the subnet prefix value. e.g. - * `192.168.0.0/29` would specify an IP range starting at 192.168.0.0 with a - * prefix size of 29 bits. - * `/16` would specify a prefix size of 16 bits, with an automatically - * determined IP within the peered VPC. - * If unspecified, a value of `/24` will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. Immutable. The network definition that the workers are peered - * to. If this section is left empty, the workers will be peered to - * `WorkerPool.project_id` on the service producer network. Must be in the - * format `projects/{project}/global/networks/{network}`, where `{project}` - * is a project number, such as `12345`, and `{network}` is the name of a - * VPC network in the project. See - * [Understanding network configuration - * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment) - * - * Generated from protobuf field string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPeeredNetwork() - { - return $this->peered_network; - } - - /** - * Required. Immutable. The network definition that the workers are peered - * to. If this section is left empty, the workers will be peered to - * `WorkerPool.project_id` on the service producer network. Must be in the - * format `projects/{project}/global/networks/{network}`, where `{project}` - * is a project number, such as `12345`, and `{network}` is the name of a - * VPC network in the project. See - * [Understanding network configuration - * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment) - * - * Generated from protobuf field string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPeeredNetwork($var) - { - GPBUtil::checkString($var, True); - $this->peered_network = $var; - - return $this; - } - - /** - * Option to configure network egress for the workers. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * @return int - */ - public function getEgressOption() - { - return $this->egress_option; - } - - /** - * Option to configure network egress for the workers. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * @param int $var - * @return $this - */ - public function setEgressOption($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\PrivatePoolV1Config\NetworkConfig\EgressOption::class); - $this->egress_option = $var; - - return $this; - } - - /** - * Immutable. Subnet IP range within the peered network. This is specified - * in CIDR notation with a slash and the subnet prefix size. You can - * optionally specify an IP address before the subnet prefix value. e.g. - * `192.168.0.0/29` would specify an IP range starting at 192.168.0.0 with a - * prefix size of 29 bits. - * `/16` would specify a prefix size of 16 bits, with an automatically - * determined IP within the peered VPC. - * If unspecified, a value of `/24` will be used. - * - * Generated from protobuf field string peered_network_ip_range = 3 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getPeeredNetworkIpRange() - { - return $this->peered_network_ip_range; - } - - /** - * Immutable. Subnet IP range within the peered network. This is specified - * in CIDR notation with a slash and the subnet prefix size. You can - * optionally specify an IP address before the subnet prefix value. e.g. - * `192.168.0.0/29` would specify an IP range starting at 192.168.0.0 with a - * prefix size of 29 bits. - * `/16` would specify a prefix size of 16 bits, with an automatically - * determined IP within the peered VPC. - * If unspecified, a value of `/24` will be used. - * - * Generated from protobuf field string peered_network_ip_range = 3 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setPeeredNetworkIpRange($var) - { - GPBUtil::checkString($var, True); - $this->peered_network_ip_range = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NetworkConfig::class, \Google\Cloud\Build\V1\PrivatePoolV1Config_NetworkConfig::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig/EgressOption.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig/EgressOption.php deleted file mode 100644 index 585945eb4ad4..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/NetworkConfig/EgressOption.php +++ /dev/null @@ -1,66 +0,0 @@ -google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption - */ -class EgressOption -{ - /** - * If set, defaults to PUBLIC_EGRESS. - * - * Generated from protobuf enum EGRESS_OPTION_UNSPECIFIED = 0; - */ - const EGRESS_OPTION_UNSPECIFIED = 0; - /** - * If set, workers are created without any public address, which prevents - * network egress to public IPs unless a network proxy is configured. - * - * Generated from protobuf enum NO_PUBLIC_EGRESS = 1; - */ - const NO_PUBLIC_EGRESS = 1; - /** - * If set, workers are created with a public address which allows for - * public internet egress. - * - * Generated from protobuf enum PUBLIC_EGRESS = 2; - */ - const PUBLIC_EGRESS = 2; - - private static $valueToName = [ - self::EGRESS_OPTION_UNSPECIFIED => 'EGRESS_OPTION_UNSPECIFIED', - self::NO_PUBLIC_EGRESS => 'NO_PUBLIC_EGRESS', - self::PUBLIC_EGRESS => 'PUBLIC_EGRESS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(EgressOption::class, \Google\Cloud\Build\V1\PrivatePoolV1Config_NetworkConfig_EgressOption::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/WorkerConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/WorkerConfig.php deleted file mode 100644 index 0f6dd5eefa90..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config/WorkerConfig.php +++ /dev/null @@ -1,133 +0,0 @@ -google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig - */ -class WorkerConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Machine type of a worker, such as `e2-medium`. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * If left blank, Cloud Build will use a sensible default. - * - * Generated from protobuf field string machine_type = 1; - */ - protected $machine_type = ''; - /** - * Size of the disk attached to the worker, in GB. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * Specify a value of up to 2000. If `0` is specified, Cloud Build will use - * a standard disk size. - * - * Generated from protobuf field int64 disk_size_gb = 2; - */ - protected $disk_size_gb = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $machine_type - * Machine type of a worker, such as `e2-medium`. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * If left blank, Cloud Build will use a sensible default. - * @type int|string $disk_size_gb - * Size of the disk attached to the worker, in GB. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * Specify a value of up to 2000. If `0` is specified, Cloud Build will use - * a standard disk size. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Machine type of a worker, such as `e2-medium`. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * If left blank, Cloud Build will use a sensible default. - * - * Generated from protobuf field string machine_type = 1; - * @return string - */ - public function getMachineType() - { - return $this->machine_type; - } - - /** - * Machine type of a worker, such as `e2-medium`. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * If left blank, Cloud Build will use a sensible default. - * - * Generated from protobuf field string machine_type = 1; - * @param string $var - * @return $this - */ - public function setMachineType($var) - { - GPBUtil::checkString($var, True); - $this->machine_type = $var; - - return $this; - } - - /** - * Size of the disk attached to the worker, in GB. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * Specify a value of up to 2000. If `0` is specified, Cloud Build will use - * a standard disk size. - * - * Generated from protobuf field int64 disk_size_gb = 2; - * @return int|string - */ - public function getDiskSizeGb() - { - return $this->disk_size_gb; - } - - /** - * Size of the disk attached to the worker, in GB. - * See [Worker pool config - * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - * Specify a value of up to 2000. If `0` is specified, Cloud Build will use - * a standard disk size. - * - * Generated from protobuf field int64 disk_size_gb = 2; - * @param int|string $var - * @return $this - */ - public function setDiskSizeGb($var) - { - GPBUtil::checkInt64($var); - $this->disk_size_gb = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(WorkerConfig::class, \Google\Cloud\Build\V1\PrivatePoolV1Config_WorkerConfig::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_NetworkConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_NetworkConfig.php deleted file mode 100644 index 54ecda0d4b52..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PrivatePoolV1Config_NetworkConfig.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.PubsubConfig - */ -class PubsubConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Name of the subscription. Format is - * `projects/{project}/subscriptions/{subscription}`. - * - * Generated from protobuf field string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $subscription = ''; - /** - * The name of the topic from which this subscription is receiving messages. - * Format is `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string topic = 2 [(.google.api.resource_reference) = { - */ - protected $topic = ''; - /** - * Service account that will make the push request. - * - * Generated from protobuf field string service_account_email = 3 [(.google.api.resource_reference) = { - */ - protected $service_account_email = ''; - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $subscription - * Output only. Name of the subscription. Format is - * `projects/{project}/subscriptions/{subscription}`. - * @type string $topic - * The name of the topic from which this subscription is receiving messages. - * Format is `projects/{project}/topics/{topic}`. - * @type string $service_account_email - * Service account that will make the push request. - * @type int $state - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Name of the subscription. Format is - * `projects/{project}/subscriptions/{subscription}`. - * - * Generated from protobuf field string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getSubscription() - { - return $this->subscription; - } - - /** - * Output only. Name of the subscription. Format is - * `projects/{project}/subscriptions/{subscription}`. - * - * Generated from protobuf field string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setSubscription($var) - { - GPBUtil::checkString($var, True); - $this->subscription = $var; - - return $this; - } - - /** - * The name of the topic from which this subscription is receiving messages. - * Format is `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string topic = 2 [(.google.api.resource_reference) = { - * @return string - */ - public function getTopic() - { - return $this->topic; - } - - /** - * The name of the topic from which this subscription is receiving messages. - * Format is `projects/{project}/topics/{topic}`. - * - * Generated from protobuf field string topic = 2 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setTopic($var) - { - GPBUtil::checkString($var, True); - $this->topic = $var; - - return $this; - } - - /** - * Service account that will make the push request. - * - * Generated from protobuf field string service_account_email = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getServiceAccountEmail() - { - return $this->service_account_email; - } - - /** - * Service account that will make the push request. - * - * Generated from protobuf field string service_account_email = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceAccountEmail($var) - { - GPBUtil::checkString($var, True); - $this->service_account_email = $var; - - return $this; - } - - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\PubsubConfig\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig/State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig/State.php deleted file mode 100644 index cefa39526389..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig/State.php +++ /dev/null @@ -1,79 +0,0 @@ -google.devtools.cloudbuild.v1.PubsubConfig.State - */ -class State -{ - /** - * The subscription configuration has not been checked. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The Pub/Sub subscription is properly configured. - * - * Generated from protobuf enum OK = 1; - */ - const OK = 1; - /** - * The subscription has been deleted. - * - * Generated from protobuf enum SUBSCRIPTION_DELETED = 2; - */ - const SUBSCRIPTION_DELETED = 2; - /** - * The topic has been deleted. - * - * Generated from protobuf enum TOPIC_DELETED = 3; - */ - const TOPIC_DELETED = 3; - /** - * Some of the subscription's field are misconfigured. - * - * Generated from protobuf enum SUBSCRIPTION_MISCONFIGURED = 4; - */ - const SUBSCRIPTION_MISCONFIGURED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::OK => 'OK', - self::SUBSCRIPTION_DELETED => 'SUBSCRIPTION_DELETED', - self::TOPIC_DELETED => 'TOPIC_DELETED', - self::SUBSCRIPTION_MISCONFIGURED => 'SUBSCRIPTION_MISCONFIGURED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Build\V1\PubsubConfig_State::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig_State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig_State.php deleted file mode 100644 index faf0b07ac656..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PubsubConfig_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.PullRequestFilter - */ -class PullRequestFilter extends \Google\Protobuf\Internal\Message -{ - /** - * Configure builds to run whether a repository owner or collaborator need to - * comment `/gcbrun`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - */ - protected $comment_control = 0; - /** - * If true, branches that do NOT match the git_ref will trigger a build. - * - * Generated from protobuf field bool invert_regex = 6; - */ - protected $invert_regex = false; - protected $git_ref; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $branch - * Regex of branches to match. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * @type int $comment_control - * Configure builds to run whether a repository owner or collaborator need to - * comment `/gcbrun`. - * @type bool $invert_regex - * If true, branches that do NOT match the git_ref will trigger a build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Regex of branches to match. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch = 2; - * @return string - */ - public function getBranch() - { - return $this->readOneof(2); - } - - public function hasBranch() - { - return $this->hasOneof(2); - } - - /** - * Regex of branches to match. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch = 2; - * @param string $var - * @return $this - */ - public function setBranch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Configure builds to run whether a repository owner or collaborator need to - * comment `/gcbrun`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * @return int - */ - public function getCommentControl() - { - return $this->comment_control; - } - - /** - * Configure builds to run whether a repository owner or collaborator need to - * comment `/gcbrun`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * @param int $var - * @return $this - */ - public function setCommentControl($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\PullRequestFilter\CommentControl::class); - $this->comment_control = $var; - - return $this; - } - - /** - * If true, branches that do NOT match the git_ref will trigger a build. - * - * Generated from protobuf field bool invert_regex = 6; - * @return bool - */ - public function getInvertRegex() - { - return $this->invert_regex; - } - - /** - * If true, branches that do NOT match the git_ref will trigger a build. - * - * Generated from protobuf field bool invert_regex = 6; - * @param bool $var - * @return $this - */ - public function setInvertRegex($var) - { - GPBUtil::checkBool($var); - $this->invert_regex = $var; - - return $this; - } - - /** - * @return string - */ - public function getGitRef() - { - return $this->whichOneof("git_ref"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter/CommentControl.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter/CommentControl.php deleted file mode 100644 index 4d6ee00a3478..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter/CommentControl.php +++ /dev/null @@ -1,66 +0,0 @@ -google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl - */ -class CommentControl -{ - /** - * Do not require comments on Pull Requests before builds are triggered. - * - * Generated from protobuf enum COMMENTS_DISABLED = 0; - */ - const COMMENTS_DISABLED = 0; - /** - * Enforce that repository owners or collaborators must comment on Pull - * Requests before builds are triggered. - * - * Generated from protobuf enum COMMENTS_ENABLED = 1; - */ - const COMMENTS_ENABLED = 1; - /** - * Enforce that repository owners or collaborators must comment on external - * contributors' Pull Requests before builds are triggered. - * - * Generated from protobuf enum COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY = 2; - */ - const COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY = 2; - - private static $valueToName = [ - self::COMMENTS_DISABLED => 'COMMENTS_DISABLED', - self::COMMENTS_ENABLED => 'COMMENTS_ENABLED', - self::COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY => 'COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CommentControl::class, \Google\Cloud\Build\V1\PullRequestFilter_CommentControl::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter_CommentControl.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter_CommentControl.php deleted file mode 100644 index b746c481d72e..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/PullRequestFilter_CommentControl.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.PushFilter - */ -class PushFilter extends \Google\Protobuf\Internal\Message -{ - /** - * When true, only trigger a build if the revision regex does NOT match the - * git_ref regex. - * - * Generated from protobuf field bool invert_regex = 4; - */ - protected $invert_regex = false; - protected $git_ref; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $branch - * Regexes matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * @type string $tag - * Regexes matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * @type bool $invert_regex - * When true, only trigger a build if the revision regex does NOT match the - * git_ref regex. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Regexes matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch = 2; - * @return string - */ - public function getBranch() - { - return $this->readOneof(2); - } - - public function hasBranch() - { - return $this->hasOneof(2); - } - - /** - * Regexes matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch = 2; - * @param string $var - * @return $this - */ - public function setBranch($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Regexes matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string tag = 3; - * @return string - */ - public function getTag() - { - return $this->readOneof(3); - } - - public function hasTag() - { - return $this->hasOneof(3); - } - - /** - * Regexes matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string tag = 3; - * @param string $var - * @return $this - */ - public function setTag($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * When true, only trigger a build if the revision regex does NOT match the - * git_ref regex. - * - * Generated from protobuf field bool invert_regex = 4; - * @return bool - */ - public function getInvertRegex() - { - return $this->invert_regex; - } - - /** - * When true, only trigger a build if the revision regex does NOT match the - * git_ref regex. - * - * Generated from protobuf field bool invert_regex = 4; - * @param bool $var - * @return $this - */ - public function setInvertRegex($var) - { - GPBUtil::checkBool($var); - $this->invert_regex = $var; - - return $this; - } - - /** - * @return string - */ - public function getGitRef() - { - return $this->whichOneof("git_ref"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookRequest.php deleted file mode 100644 index b13eb970488f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookRequest.php +++ /dev/null @@ -1,218 +0,0 @@ -google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest - */ -class ReceiveTriggerWebhookRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `ReceiveTriggerWebhook` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 5; - */ - protected $name = ''; - /** - * HTTP request body. - * - * Generated from protobuf field .google.api.HttpBody body = 1; - */ - protected $body = null; - /** - * Project in which the specified trigger lives - * - * Generated from protobuf field string project_id = 2; - */ - protected $project_id = ''; - /** - * Name of the trigger to run the payload against - * - * Generated from protobuf field string trigger = 3; - */ - protected $trigger = ''; - /** - * Secret token used for authorization if an OAuth token isn't provided. - * - * Generated from protobuf field string secret = 4; - */ - protected $secret = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `ReceiveTriggerWebhook` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type \Google\Api\HttpBody $body - * HTTP request body. - * @type string $project_id - * Project in which the specified trigger lives - * @type string $trigger - * Name of the trigger to run the payload against - * @type string $secret - * Secret token used for authorization if an OAuth token isn't provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `ReceiveTriggerWebhook` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 5; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `ReceiveTriggerWebhook` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 5; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * HTTP request body. - * - * Generated from protobuf field .google.api.HttpBody body = 1; - * @return \Google\Api\HttpBody|null - */ - public function getBody() - { - return $this->body; - } - - public function hasBody() - { - return isset($this->body); - } - - public function clearBody() - { - unset($this->body); - } - - /** - * HTTP request body. - * - * Generated from protobuf field .google.api.HttpBody body = 1; - * @param \Google\Api\HttpBody $var - * @return $this - */ - public function setBody($var) - { - GPBUtil::checkMessage($var, \Google\Api\HttpBody::class); - $this->body = $var; - - return $this; - } - - /** - * Project in which the specified trigger lives - * - * Generated from protobuf field string project_id = 2; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Project in which the specified trigger lives - * - * Generated from protobuf field string project_id = 2; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Name of the trigger to run the payload against - * - * Generated from protobuf field string trigger = 3; - * @return string - */ - public function getTrigger() - { - return $this->trigger; - } - - /** - * Name of the trigger to run the payload against - * - * Generated from protobuf field string trigger = 3; - * @param string $var - * @return $this - */ - public function setTrigger($var) - { - GPBUtil::checkString($var, True); - $this->trigger = $var; - - return $this; - } - - /** - * Secret token used for authorization if an OAuth token isn't provided. - * - * Generated from protobuf field string secret = 4; - * @return string - */ - public function getSecret() - { - return $this->secret; - } - - /** - * Secret token used for authorization if an OAuth token isn't provided. - * - * Generated from protobuf field string secret = 4; - * @param string $var - * @return $this - */ - public function setSecret($var) - { - GPBUtil::checkString($var, True); - $this->secret = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookResponse.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookResponse.php deleted file mode 100644 index b83c62b3d78f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/ReceiveTriggerWebhookResponse.php +++ /dev/null @@ -1,34 +0,0 @@ -google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse - */ -class ReceiveTriggerWebhookResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RepoSource.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RepoSource.php deleted file mode 100644 index 6ee7d02edb61..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RepoSource.php +++ /dev/null @@ -1,343 +0,0 @@ -google.devtools.cloudbuild.v1.RepoSource - */ -class RepoSource extends \Google\Protobuf\Internal\Message -{ - /** - * ID of the project that owns the Cloud Source Repository. If omitted, the - * project ID requesting the build is assumed. - * - * Generated from protobuf field string project_id = 1; - */ - protected $project_id = ''; - /** - * Name of the Cloud Source Repository. - * - * Generated from protobuf field string repo_name = 2; - */ - protected $repo_name = ''; - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 7; - */ - protected $dir = ''; - /** - * Only trigger a build if the revision regex does NOT match the revision - * regex. - * - * Generated from protobuf field bool invert_regex = 8; - */ - protected $invert_regex = false; - /** - * Substitutions to use in a triggered build. - * Should only be used with RunBuildTrigger - * - * Generated from protobuf field map substitutions = 9; - */ - private $substitutions; - protected $revision; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * ID of the project that owns the Cloud Source Repository. If omitted, the - * project ID requesting the build is assumed. - * @type string $repo_name - * Name of the Cloud Source Repository. - * @type string $branch_name - * Regex matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * @type string $tag_name - * Regex matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * @type string $commit_sha - * Explicit commit SHA to build. - * @type string $dir - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * @type bool $invert_regex - * Only trigger a build if the revision regex does NOT match the revision - * regex. - * @type array|\Google\Protobuf\Internal\MapField $substitutions - * Substitutions to use in a triggered build. - * Should only be used with RunBuildTrigger - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * ID of the project that owns the Cloud Source Repository. If omitted, the - * project ID requesting the build is assumed. - * - * Generated from protobuf field string project_id = 1; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * ID of the project that owns the Cloud Source Repository. If omitted, the - * project ID requesting the build is assumed. - * - * Generated from protobuf field string project_id = 1; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Name of the Cloud Source Repository. - * - * Generated from protobuf field string repo_name = 2; - * @return string - */ - public function getRepoName() - { - return $this->repo_name; - } - - /** - * Name of the Cloud Source Repository. - * - * Generated from protobuf field string repo_name = 2; - * @param string $var - * @return $this - */ - public function setRepoName($var) - { - GPBUtil::checkString($var, True); - $this->repo_name = $var; - - return $this; - } - - /** - * Regex matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch_name = 3; - * @return string - */ - public function getBranchName() - { - return $this->readOneof(3); - } - - public function hasBranchName() - { - return $this->hasOneof(3); - } - - /** - * Regex matching branches to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string branch_name = 3; - * @param string $var - * @return $this - */ - public function setBranchName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Regex matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string tag_name = 4; - * @return string - */ - public function getTagName() - { - return $this->readOneof(4); - } - - public function hasTagName() - { - return $this->hasOneof(4); - } - - /** - * Regex matching tags to build. - * The syntax of the regular expressions accepted is the syntax accepted by - * RE2 and described at https://github.com/google/re2/wiki/Syntax - * - * Generated from protobuf field string tag_name = 4; - * @param string $var - * @return $this - */ - public function setTagName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Explicit commit SHA to build. - * - * Generated from protobuf field string commit_sha = 5; - * @return string - */ - public function getCommitSha() - { - return $this->readOneof(5); - } - - public function hasCommitSha() - { - return $this->hasOneof(5); - } - - /** - * Explicit commit SHA to build. - * - * Generated from protobuf field string commit_sha = 5; - * @param string $var - * @return $this - */ - public function setCommitSha($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 7; - * @return string - */ - public function getDir() - { - return $this->dir; - } - - /** - * Directory, relative to the source root, in which to run the build. - * This must be a relative path. If a step's `dir` is specified and is an - * absolute path, this value is ignored for that step's execution. - * - * Generated from protobuf field string dir = 7; - * @param string $var - * @return $this - */ - public function setDir($var) - { - GPBUtil::checkString($var, True); - $this->dir = $var; - - return $this; - } - - /** - * Only trigger a build if the revision regex does NOT match the revision - * regex. - * - * Generated from protobuf field bool invert_regex = 8; - * @return bool - */ - public function getInvertRegex() - { - return $this->invert_regex; - } - - /** - * Only trigger a build if the revision regex does NOT match the revision - * regex. - * - * Generated from protobuf field bool invert_regex = 8; - * @param bool $var - * @return $this - */ - public function setInvertRegex($var) - { - GPBUtil::checkBool($var); - $this->invert_regex = $var; - - return $this; - } - - /** - * Substitutions to use in a triggered build. - * Should only be used with RunBuildTrigger - * - * Generated from protobuf field map substitutions = 9; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSubstitutions() - { - return $this->substitutions; - } - - /** - * Substitutions to use in a triggered build. - * Should only be used with RunBuildTrigger - * - * Generated from protobuf field map substitutions = 9; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSubstitutions($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->substitutions = $arr; - - return $this; - } - - /** - * @return string - */ - public function getRevision() - { - return $this->whichOneof("revision"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Results.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Results.php deleted file mode 100644 index 11963b38856d..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Results.php +++ /dev/null @@ -1,377 +0,0 @@ -google.devtools.cloudbuild.v1.Results - */ -class Results extends \Google\Protobuf\Internal\Message -{ - /** - * Container images that were built as a part of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - private $images; - /** - * List of build step digests, in the order corresponding to build step - * indices. - * - * Generated from protobuf field repeated string build_step_images = 3; - */ - private $build_step_images; - /** - * Path to the artifact manifest for non-container artifacts uploaded to Cloud - * Storage. Only populated when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field string artifact_manifest = 4; - */ - protected $artifact_manifest = ''; - /** - * Number of non-container artifacts uploaded to Cloud Storage. Only populated - * when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field int64 num_artifacts = 5; - */ - protected $num_artifacts = 0; - /** - * List of build step outputs, produced by builder images, in the order - * corresponding to build step indices. - * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) - * can produce this output by writing to `$BUILDER_OUTPUT/output`. - * Only the first 4KB of data is stored. - * - * Generated from protobuf field repeated bytes build_step_outputs = 6; - */ - private $build_step_outputs; - /** - * Time to push all non-container artifacts to Cloud Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - protected $artifact_timing = null; - /** - * Python artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedPythonPackage python_packages = 8; - */ - private $python_packages; - /** - * Maven artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedMavenArtifact maven_artifacts = 9; - */ - private $maven_artifacts; - /** - * Npm packages uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedNpmPackage npm_packages = 12; - */ - private $npm_packages; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\BuiltImage>|\Google\Protobuf\Internal\RepeatedField $images - * Container images that were built as a part of the build. - * @type array|\Google\Protobuf\Internal\RepeatedField $build_step_images - * List of build step digests, in the order corresponding to build step - * indices. - * @type string $artifact_manifest - * Path to the artifact manifest for non-container artifacts uploaded to Cloud - * Storage. Only populated when artifacts are uploaded to Cloud Storage. - * @type int|string $num_artifacts - * Number of non-container artifacts uploaded to Cloud Storage. Only populated - * when artifacts are uploaded to Cloud Storage. - * @type array|\Google\Protobuf\Internal\RepeatedField $build_step_outputs - * List of build step outputs, produced by builder images, in the order - * corresponding to build step indices. - * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) - * can produce this output by writing to `$BUILDER_OUTPUT/output`. - * Only the first 4KB of data is stored. - * @type \Google\Cloud\Build\V1\TimeSpan $artifact_timing - * Time to push all non-container artifacts to Cloud Storage. - * @type array<\Google\Cloud\Build\V1\UploadedPythonPackage>|\Google\Protobuf\Internal\RepeatedField $python_packages - * Python artifacts uploaded to Artifact Registry at the end of the build. - * @type array<\Google\Cloud\Build\V1\UploadedMavenArtifact>|\Google\Protobuf\Internal\RepeatedField $maven_artifacts - * Maven artifacts uploaded to Artifact Registry at the end of the build. - * @type array<\Google\Cloud\Build\V1\UploadedNpmPackage>|\Google\Protobuf\Internal\RepeatedField $npm_packages - * Npm packages uploaded to Artifact Registry at the end of the build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Container images that were built as a part of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getImages() - { - return $this->images; - } - - /** - * Container images that were built as a part of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - * @param array<\Google\Cloud\Build\V1\BuiltImage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setImages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\BuiltImage::class); - $this->images = $arr; - - return $this; - } - - /** - * List of build step digests, in the order corresponding to build step - * indices. - * - * Generated from protobuf field repeated string build_step_images = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBuildStepImages() - { - return $this->build_step_images; - } - - /** - * List of build step digests, in the order corresponding to build step - * indices. - * - * Generated from protobuf field repeated string build_step_images = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBuildStepImages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->build_step_images = $arr; - - return $this; - } - - /** - * Path to the artifact manifest for non-container artifacts uploaded to Cloud - * Storage. Only populated when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field string artifact_manifest = 4; - * @return string - */ - public function getArtifactManifest() - { - return $this->artifact_manifest; - } - - /** - * Path to the artifact manifest for non-container artifacts uploaded to Cloud - * Storage. Only populated when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field string artifact_manifest = 4; - * @param string $var - * @return $this - */ - public function setArtifactManifest($var) - { - GPBUtil::checkString($var, True); - $this->artifact_manifest = $var; - - return $this; - } - - /** - * Number of non-container artifacts uploaded to Cloud Storage. Only populated - * when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field int64 num_artifacts = 5; - * @return int|string - */ - public function getNumArtifacts() - { - return $this->num_artifacts; - } - - /** - * Number of non-container artifacts uploaded to Cloud Storage. Only populated - * when artifacts are uploaded to Cloud Storage. - * - * Generated from protobuf field int64 num_artifacts = 5; - * @param int|string $var - * @return $this - */ - public function setNumArtifacts($var) - { - GPBUtil::checkInt64($var); - $this->num_artifacts = $var; - - return $this; - } - - /** - * List of build step outputs, produced by builder images, in the order - * corresponding to build step indices. - * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) - * can produce this output by writing to `$BUILDER_OUTPUT/output`. - * Only the first 4KB of data is stored. - * - * Generated from protobuf field repeated bytes build_step_outputs = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBuildStepOutputs() - { - return $this->build_step_outputs; - } - - /** - * List of build step outputs, produced by builder images, in the order - * corresponding to build step indices. - * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) - * can produce this output by writing to `$BUILDER_OUTPUT/output`. - * Only the first 4KB of data is stored. - * - * Generated from protobuf field repeated bytes build_step_outputs = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBuildStepOutputs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::BYTES); - $this->build_step_outputs = $arr; - - return $this; - } - - /** - * Time to push all non-container artifacts to Cloud Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getArtifactTiming() - { - return $this->artifact_timing; - } - - public function hasArtifactTiming() - { - return isset($this->artifact_timing); - } - - public function clearArtifactTiming() - { - unset($this->artifact_timing); - } - - /** - * Time to push all non-container artifacts to Cloud Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setArtifactTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->artifact_timing = $var; - - return $this; - } - - /** - * Python artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedPythonPackage python_packages = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPythonPackages() - { - return $this->python_packages; - } - - /** - * Python artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedPythonPackage python_packages = 8; - * @param array<\Google\Cloud\Build\V1\UploadedPythonPackage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPythonPackages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\UploadedPythonPackage::class); - $this->python_packages = $arr; - - return $this; - } - - /** - * Maven artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedMavenArtifact maven_artifacts = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMavenArtifacts() - { - return $this->maven_artifacts; - } - - /** - * Maven artifacts uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedMavenArtifact maven_artifacts = 9; - * @param array<\Google\Cloud\Build\V1\UploadedMavenArtifact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMavenArtifacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\UploadedMavenArtifact::class); - $this->maven_artifacts = $arr; - - return $this; - } - - /** - * Npm packages uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedNpmPackage npm_packages = 12; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNpmPackages() - { - return $this->npm_packages; - } - - /** - * Npm packages uploaded to Artifact Registry at the end of the build. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.UploadedNpmPackage npm_packages = 12; - * @param array<\Google\Cloud\Build\V1\UploadedNpmPackage>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNpmPackages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\UploadedNpmPackage::class); - $this->npm_packages = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RetryBuildRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RetryBuildRequest.php deleted file mode 100644 index 0c248cafa3dc..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RetryBuildRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v1.RetryBuildRequest - */ -class RetryBuildRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Build` to retry. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. Build ID of the original build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Build` to retry. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type string $project_id - * Required. ID of the project. - * @type string $id - * Required. Build ID of the original build. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Build` to retry. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Build` to retry. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * - * Generated from protobuf field string name = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. Build ID of the original build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * Required. Build ID of the original build. - * - * Generated from protobuf field string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RunBuildTriggerRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RunBuildTriggerRequest.php deleted file mode 100644 index d1ad4c73e02f..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/RunBuildTriggerRequest.php +++ /dev/null @@ -1,183 +0,0 @@ -google.devtools.cloudbuild.v1.RunBuildTriggerRequest - */ -class RunBuildTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the `Trigger` to run. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. ID of the trigger. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger_id = ''; - /** - * Source to build against this trigger. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - protected $source = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the `Trigger` to run. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type string $project_id - * Required. ID of the project. - * @type string $trigger_id - * Required. ID of the trigger. - * @type \Google\Cloud\Build\V1\RepoSource $source - * Source to build against this trigger. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The name of the `Trigger` to run. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the `Trigger` to run. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * - * Generated from protobuf field string name = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. ID of the trigger. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * Required. ID of the trigger. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - - /** - * Source to build against this trigger. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource source = 3; - * @return \Google\Cloud\Build\V1\RepoSource|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Source to build against this trigger. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource source = 3; - * @param \Google\Cloud\Build\V1\RepoSource $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\RepoSource::class); - $this->source = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secret.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secret.php deleted file mode 100644 index 619036d3ec3b..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secret.php +++ /dev/null @@ -1,121 +0,0 @@ -google.devtools.cloudbuild.v1.Secret - */ -class Secret extends \Google\Protobuf\Internal\Message -{ - /** - * Cloud KMS key name to use to decrypt these envs. - * - * Generated from protobuf field string kms_key_name = 1; - */ - protected $kms_key_name = ''; - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map secret_env = 3; - */ - private $secret_env; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $kms_key_name - * Cloud KMS key name to use to decrypt these envs. - * @type array|\Google\Protobuf\Internal\MapField $secret_env - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Cloud KMS key name to use to decrypt these envs. - * - * Generated from protobuf field string kms_key_name = 1; - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Cloud KMS key name to use to decrypt these envs. - * - * Generated from protobuf field string kms_key_name = 1; - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map secret_env = 3; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSecretEnv() - { - return $this->secret_env; - } - - /** - * Map of environment variable name to its encrypted value. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. Values can be at most - * 64 KB in size. There can be at most 100 secret values across all of a - * build's secrets. - * - * Generated from protobuf field map secret_env = 3; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSecretEnv($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::BYTES); - $this->secret_env = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SecretManagerSecret.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SecretManagerSecret.php deleted file mode 100644 index 835067891120..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SecretManagerSecret.php +++ /dev/null @@ -1,113 +0,0 @@ -google.devtools.cloudbuild.v1.SecretManagerSecret - */ -class SecretManagerSecret extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of the SecretVersion. In format: - * projects/*/secrets/*/versions/* - * - * Generated from protobuf field string version_name = 1 [(.google.api.resource_reference) = { - */ - protected $version_name = ''; - /** - * Environment variable name to associate with the secret. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. - * - * Generated from protobuf field string env = 2; - */ - protected $env = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $version_name - * Resource name of the SecretVersion. In format: - * projects/*/secrets/*/versions/* - * @type string $env - * Environment variable name to associate with the secret. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of the SecretVersion. In format: - * projects/*/secrets/*/versions/* - * - * Generated from protobuf field string version_name = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getVersionName() - { - return $this->version_name; - } - - /** - * Resource name of the SecretVersion. In format: - * projects/*/secrets/*/versions/* - * - * Generated from protobuf field string version_name = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVersionName($var) - { - GPBUtil::checkString($var, True); - $this->version_name = $var; - - return $this; - } - - /** - * Environment variable name to associate with the secret. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. - * - * Generated from protobuf field string env = 2; - * @return string - */ - public function getEnv() - { - return $this->env; - } - - /** - * Environment variable name to associate with the secret. - * Secret environment variables must be unique across all of a build's - * secrets, and must be used by at least one build step. - * - * Generated from protobuf field string env = 2; - * @param string $var - * @return $this - */ - public function setEnv($var) - { - GPBUtil::checkString($var, True); - $this->env = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secrets.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secrets.php deleted file mode 100644 index b43d3c3f25c2..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Secrets.php +++ /dev/null @@ -1,105 +0,0 @@ -google.devtools.cloudbuild.v1.Secrets - */ -class Secrets extends \Google\Protobuf\Internal\Message -{ - /** - * Secrets in Secret Manager and associated secret environment variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - private $secret_manager; - /** - * Secrets encrypted with KMS key and the associated secret environment - * variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - private $inline; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V1\SecretManagerSecret>|\Google\Protobuf\Internal\RepeatedField $secret_manager - * Secrets in Secret Manager and associated secret environment variable. - * @type array<\Google\Cloud\Build\V1\InlineSecret>|\Google\Protobuf\Internal\RepeatedField $inline - * Secrets encrypted with KMS key and the associated secret environment - * variable. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Secrets in Secret Manager and associated secret environment variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecretManager() - { - return $this->secret_manager; - } - - /** - * Secrets in Secret Manager and associated secret environment variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - * @param array<\Google\Cloud\Build\V1\SecretManagerSecret>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecretManager($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\SecretManagerSecret::class); - $this->secret_manager = $arr; - - return $this; - } - - /** - * Secrets encrypted with KMS key and the associated secret environment - * variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInline() - { - return $this->inline; - } - - /** - * Secrets encrypted with KMS key and the associated secret environment - * variable. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - * @param array<\Google\Cloud\Build\V1\InlineSecret>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInline($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\InlineSecret::class); - $this->inline = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Source.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Source.php deleted file mode 100644 index d4a53ad18f19..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Source.php +++ /dev/null @@ -1,183 +0,0 @@ -google.devtools.cloudbuild.v1.Source - */ -class Source extends \Google\Protobuf\Internal\Message -{ - protected $source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V1\StorageSource $storage_source - * If provided, get the source from this location in Google Cloud Storage. - * @type \Google\Cloud\Build\V1\RepoSource $repo_source - * If provided, get the source from this location in a Cloud Source - * Repository. - * @type \Google\Cloud\Build\V1\GitSource $git_source - * If provided, get the source from this Git repository. - * @type \Google\Cloud\Build\V1\StorageSourceManifest $storage_source_manifest - * If provided, get the source from this manifest in Google Cloud Storage. - * This feature is in Preview; see description - * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * If provided, get the source from this location in Google Cloud Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * @return \Google\Cloud\Build\V1\StorageSource|null - */ - public function getStorageSource() - { - return $this->readOneof(2); - } - - public function hasStorageSource() - { - return $this->hasOneof(2); - } - - /** - * If provided, get the source from this location in Google Cloud Storage. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * @param \Google\Cloud\Build\V1\StorageSource $var - * @return $this - */ - public function setStorageSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\StorageSource::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * If provided, get the source from this location in a Cloud Source - * Repository. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * @return \Google\Cloud\Build\V1\RepoSource|null - */ - public function getRepoSource() - { - return $this->readOneof(3); - } - - public function hasRepoSource() - { - return $this->hasOneof(3); - } - - /** - * If provided, get the source from this location in a Cloud Source - * Repository. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * @param \Google\Cloud\Build\V1\RepoSource $var - * @return $this - */ - public function setRepoSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\RepoSource::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * If provided, get the source from this Git repository. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.GitSource git_source = 5; - * @return \Google\Cloud\Build\V1\GitSource|null - */ - public function getGitSource() - { - return $this->readOneof(5); - } - - public function hasGitSource() - { - return $this->hasOneof(5); - } - - /** - * If provided, get the source from this Git repository. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.GitSource git_source = 5; - * @param \Google\Cloud\Build\V1\GitSource $var - * @return $this - */ - public function setGitSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\GitSource::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * If provided, get the source from this manifest in Google Cloud Storage. - * This feature is in Preview; see description - * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * @return \Google\Cloud\Build\V1\StorageSourceManifest|null - */ - public function getStorageSourceManifest() - { - return $this->readOneof(8); - } - - public function hasStorageSourceManifest() - { - return $this->hasOneof(8); - } - - /** - * If provided, get the source from this manifest in Google Cloud Storage. - * This feature is in Preview; see description - * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * @param \Google\Cloud\Build\V1\StorageSourceManifest $var - * @return $this - */ - public function setStorageSourceManifest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\StorageSourceManifest::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * @return string - */ - public function getSource() - { - return $this->whichOneof("source"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SourceProvenance.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SourceProvenance.php deleted file mode 100644 index fb9f98979597..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/SourceProvenance.php +++ /dev/null @@ -1,244 +0,0 @@ -google.devtools.cloudbuild.v1.SourceProvenance - */ -class SourceProvenance extends \Google\Protobuf\Internal\Message -{ - /** - * A copy of the build's `source.storage_source`, if exists, with any - * generations resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - protected $resolved_storage_source = null; - /** - * A copy of the build's `source.repo_source`, if exists, with any - * revisions resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - protected $resolved_repo_source = null; - /** - * A copy of the build's `source.storage_source_manifest`, if exists, with any - * revisions resolved. - * This feature is in Preview. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - */ - protected $resolved_storage_source_manifest = null; - /** - * Output only. Hash(es) of the build source, which can be used to verify that - * the original source integrity was maintained in the build. Note that - * `FileHashes` will only be populated if `BuildOptions` has requested a - * `SourceProvenanceHash`. - * The keys to this map are file paths used as build source and the values - * contain the hash values for those files. - * If the build source came in a single package such as a gzipped tarfile - * (`.tar.gz`), the `FileHash` will be for the single path to that file. - * - * Generated from protobuf field map file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $file_hashes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V1\StorageSource $resolved_storage_source - * A copy of the build's `source.storage_source`, if exists, with any - * generations resolved. - * @type \Google\Cloud\Build\V1\RepoSource $resolved_repo_source - * A copy of the build's `source.repo_source`, if exists, with any - * revisions resolved. - * @type \Google\Cloud\Build\V1\StorageSourceManifest $resolved_storage_source_manifest - * A copy of the build's `source.storage_source_manifest`, if exists, with any - * revisions resolved. - * This feature is in Preview. - * @type array|\Google\Protobuf\Internal\MapField $file_hashes - * Output only. Hash(es) of the build source, which can be used to verify that - * the original source integrity was maintained in the build. Note that - * `FileHashes` will only be populated if `BuildOptions` has requested a - * `SourceProvenanceHash`. - * The keys to this map are file paths used as build source and the values - * contain the hash values for those files. - * If the build source came in a single package such as a gzipped tarfile - * (`.tar.gz`), the `FileHash` will be for the single path to that file. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * A copy of the build's `source.storage_source`, if exists, with any - * generations resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * @return \Google\Cloud\Build\V1\StorageSource|null - */ - public function getResolvedStorageSource() - { - return $this->resolved_storage_source; - } - - public function hasResolvedStorageSource() - { - return isset($this->resolved_storage_source); - } - - public function clearResolvedStorageSource() - { - unset($this->resolved_storage_source); - } - - /** - * A copy of the build's `source.storage_source`, if exists, with any - * generations resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * @param \Google\Cloud\Build\V1\StorageSource $var - * @return $this - */ - public function setResolvedStorageSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\StorageSource::class); - $this->resolved_storage_source = $var; - - return $this; - } - - /** - * A copy of the build's `source.repo_source`, if exists, with any - * revisions resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * @return \Google\Cloud\Build\V1\RepoSource|null - */ - public function getResolvedRepoSource() - { - return $this->resolved_repo_source; - } - - public function hasResolvedRepoSource() - { - return isset($this->resolved_repo_source); - } - - public function clearResolvedRepoSource() - { - unset($this->resolved_repo_source); - } - - /** - * A copy of the build's `source.repo_source`, if exists, with any - * revisions resolved. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * @param \Google\Cloud\Build\V1\RepoSource $var - * @return $this - */ - public function setResolvedRepoSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\RepoSource::class); - $this->resolved_repo_source = $var; - - return $this; - } - - /** - * A copy of the build's `source.storage_source_manifest`, if exists, with any - * revisions resolved. - * This feature is in Preview. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * @return \Google\Cloud\Build\V1\StorageSourceManifest|null - */ - public function getResolvedStorageSourceManifest() - { - return $this->resolved_storage_source_manifest; - } - - public function hasResolvedStorageSourceManifest() - { - return isset($this->resolved_storage_source_manifest); - } - - public function clearResolvedStorageSourceManifest() - { - unset($this->resolved_storage_source_manifest); - } - - /** - * A copy of the build's `source.storage_source_manifest`, if exists, with any - * revisions resolved. - * This feature is in Preview. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * @param \Google\Cloud\Build\V1\StorageSourceManifest $var - * @return $this - */ - public function setResolvedStorageSourceManifest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\StorageSourceManifest::class); - $this->resolved_storage_source_manifest = $var; - - return $this; - } - - /** - * Output only. Hash(es) of the build source, which can be used to verify that - * the original source integrity was maintained in the build. Note that - * `FileHashes` will only be populated if `BuildOptions` has requested a - * `SourceProvenanceHash`. - * The keys to this map are file paths used as build source and the values - * contain the hash values for those files. - * If the build source came in a single package such as a gzipped tarfile - * (`.tar.gz`), the `FileHash` will be for the single path to that file. - * - * Generated from protobuf field map file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getFileHashes() - { - return $this->file_hashes; - } - - /** - * Output only. Hash(es) of the build source, which can be used to verify that - * the original source integrity was maintained in the build. Note that - * `FileHashes` will only be populated if `BuildOptions` has requested a - * `SourceProvenanceHash`. - * The keys to this map are file paths used as build source and the values - * contain the hash values for those files. - * If the build source came in a single package such as a gzipped tarfile - * (`.tar.gz`), the `FileHash` will be for the single path to that file. - * - * Generated from protobuf field map file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setFileHashes($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V1\FileHashes::class); - $this->file_hashes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSource.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSource.php deleted file mode 100644 index a78430aece40..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSource.php +++ /dev/null @@ -1,155 +0,0 @@ -google.devtools.cloudbuild.v1.StorageSource - */ -class StorageSource extends \Google\Protobuf\Internal\Message -{ - /** - * Google Cloud Storage bucket containing the source (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - */ - protected $bucket = ''; - /** - * Google Cloud Storage object containing the source. - * This object must be a gzipped archive file (`.tar.gz`) containing source to - * build. - * - * Generated from protobuf field string object = 2; - */ - protected $object = ''; - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - */ - protected $generation = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $bucket - * Google Cloud Storage bucket containing the source (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * @type string $object - * Google Cloud Storage object containing the source. - * This object must be a gzipped archive file (`.tar.gz`) containing source to - * build. - * @type int|string $generation - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Google Cloud Storage bucket containing the source (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - * @return string - */ - public function getBucket() - { - return $this->bucket; - } - - /** - * Google Cloud Storage bucket containing the source (see - * [Bucket Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - * @param string $var - * @return $this - */ - public function setBucket($var) - { - GPBUtil::checkString($var, True); - $this->bucket = $var; - - return $this; - } - - /** - * Google Cloud Storage object containing the source. - * This object must be a gzipped archive file (`.tar.gz`) containing source to - * build. - * - * Generated from protobuf field string object = 2; - * @return string - */ - public function getObject() - { - return $this->object; - } - - /** - * Google Cloud Storage object containing the source. - * This object must be a gzipped archive file (`.tar.gz`) containing source to - * build. - * - * Generated from protobuf field string object = 2; - * @param string $var - * @return $this - */ - public function setObject($var) - { - GPBUtil::checkString($var, True); - $this->object = $var; - - return $this; - } - - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - * @return int|string - */ - public function getGeneration() - { - return $this->generation; - } - - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - * @param int|string $var - * @return $this - */ - public function setGeneration($var) - { - GPBUtil::checkInt64($var); - $this->generation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSourceManifest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSourceManifest.php deleted file mode 100644 index 72d8227269e0..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/StorageSourceManifest.php +++ /dev/null @@ -1,153 +0,0 @@ -google.devtools.cloudbuild.v1.StorageSourceManifest - */ -class StorageSourceManifest extends \Google\Protobuf\Internal\Message -{ - /** - * Google Cloud Storage bucket containing the source manifest (see [Bucket - * Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - */ - protected $bucket = ''; - /** - * Google Cloud Storage object containing the source manifest. - * This object must be a JSON file. - * - * Generated from protobuf field string object = 2; - */ - protected $object = ''; - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - */ - protected $generation = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $bucket - * Google Cloud Storage bucket containing the source manifest (see [Bucket - * Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * @type string $object - * Google Cloud Storage object containing the source manifest. - * This object must be a JSON file. - * @type int|string $generation - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Google Cloud Storage bucket containing the source manifest (see [Bucket - * Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - * @return string - */ - public function getBucket() - { - return $this->bucket; - } - - /** - * Google Cloud Storage bucket containing the source manifest (see [Bucket - * Name - * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - * - * Generated from protobuf field string bucket = 1; - * @param string $var - * @return $this - */ - public function setBucket($var) - { - GPBUtil::checkString($var, True); - $this->bucket = $var; - - return $this; - } - - /** - * Google Cloud Storage object containing the source manifest. - * This object must be a JSON file. - * - * Generated from protobuf field string object = 2; - * @return string - */ - public function getObject() - { - return $this->object; - } - - /** - * Google Cloud Storage object containing the source manifest. - * This object must be a JSON file. - * - * Generated from protobuf field string object = 2; - * @param string $var - * @return $this - */ - public function setObject($var) - { - GPBUtil::checkString($var, True); - $this->object = $var; - - return $this; - } - - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - * @return int|string - */ - public function getGeneration() - { - return $this->generation; - } - - /** - * Google Cloud Storage generation for the object. If the generation is - * omitted, the latest generation will be used. - * - * Generated from protobuf field int64 generation = 3; - * @param int|string $var - * @return $this - */ - public function setGeneration($var) - { - GPBUtil::checkInt64($var); - $this->generation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/TimeSpan.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/TimeSpan.php deleted file mode 100644 index 848a10c124f5..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/TimeSpan.php +++ /dev/null @@ -1,121 +0,0 @@ -google.devtools.cloudbuild.v1.TimeSpan - */ -class TimeSpan extends \Google\Protobuf\Internal\Message -{ - /** - * Start of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - */ - protected $start_time = null; - /** - * End of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $start_time - * Start of time span. - * @type \Google\Protobuf\Timestamp $end_time - * End of time span. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Start of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Start of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * End of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * End of time span. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateBuildTriggerRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateBuildTriggerRequest.php deleted file mode 100644 index 33dfb6977484..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateBuildTriggerRequest.php +++ /dev/null @@ -1,145 +0,0 @@ -google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest - */ -class UpdateBuildTriggerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $project_id = ''; - /** - * Required. ID of the `BuildTrigger` to update. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger_id = ''; - /** - * Required. `BuildTrigger` to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $trigger = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $project_id - * Required. ID of the project that owns the trigger. - * @type string $trigger_id - * Required. ID of the `BuildTrigger` to update. - * @type \Google\Cloud\Build\V1\BuildTrigger $trigger - * Required. `BuildTrigger` to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getProjectId() - { - return $this->project_id; - } - - /** - * Required. ID of the project that owns the trigger. - * - * Generated from protobuf field string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setProjectId($var) - { - GPBUtil::checkString($var, True); - $this->project_id = $var; - - return $this; - } - - /** - * Required. ID of the `BuildTrigger` to update. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTriggerId() - { - return $this->trigger_id; - } - - /** - * Required. ID of the `BuildTrigger` to update. - * - * Generated from protobuf field string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTriggerId($var) - { - GPBUtil::checkString($var, True); - $this->trigger_id = $var; - - return $this; - } - - /** - * Required. `BuildTrigger` to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V1\BuildTrigger|null - */ - public function getTrigger() - { - return $this->trigger; - } - - public function hasTrigger() - { - return isset($this->trigger); - } - - public function clearTrigger() - { - unset($this->trigger); - } - - /** - * Required. `BuildTrigger` to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V1\BuildTrigger $var - * @return $this - */ - public function setTrigger($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\BuildTrigger::class); - $this->trigger = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolOperationMetadata.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolOperationMetadata.php deleted file mode 100644 index 52ae96a77d45..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolOperationMetadata.php +++ /dev/null @@ -1,163 +0,0 @@ -google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata - */ -class UpdateWorkerPoolOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the `WorkerPool` being updated. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - */ - protected $worker_pool = ''; - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - */ - protected $complete_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $worker_pool - * The resource name of the `WorkerPool` being updated. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * @type \Google\Protobuf\Timestamp $create_time - * Time the operation was created. - * @type \Google\Protobuf\Timestamp $complete_time - * Time the operation was completed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the `WorkerPool` being updated. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getWorkerPool() - { - return $this->worker_pool; - } - - /** - * The resource name of the `WorkerPool` being updated. - * Format: - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * - * Generated from protobuf field string worker_pool = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setWorkerPool($var) - { - GPBUtil::checkString($var, True); - $this->worker_pool = $var; - - return $this; - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCompleteTime() - { - return $this->complete_time; - } - - public function hasCompleteTime() - { - return isset($this->complete_time); - } - - public function clearCompleteTime() - { - unset($this->complete_time); - } - - /** - * Time the operation was completed. - * - * Generated from protobuf field .google.protobuf.Timestamp complete_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCompleteTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->complete_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolRequest.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolRequest.php deleted file mode 100644 index aa46fa7222c2..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UpdateWorkerPoolRequest.php +++ /dev/null @@ -1,167 +0,0 @@ -google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest - */ -class UpdateWorkerPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The `WorkerPool` to update. - * The `name` field is used to identify the `WorkerPool` to update. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $worker_pool = null; - /** - * A mask specifying which fields in `worker_pool` to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V1\WorkerPool $worker_pool - * Required. The `WorkerPool` to update. - * The `name` field is used to identify the `WorkerPool` to update. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @type \Google\Protobuf\FieldMask $update_mask - * A mask specifying which fields in `worker_pool` to update. - * @type bool $validate_only - * If set, validate the request and preview the response, but do not actually - * post it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. The `WorkerPool` to update. - * The `name` field is used to identify the `WorkerPool` to update. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V1\WorkerPool|null - */ - public function getWorkerPool() - { - return $this->worker_pool; - } - - public function hasWorkerPool() - { - return isset($this->worker_pool); - } - - public function clearWorkerPool() - { - unset($this->worker_pool); - } - - /** - * Required. The `WorkerPool` to update. - * The `name` field is used to identify the `WorkerPool` to update. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V1\WorkerPool $var - * @return $this - */ - public function setWorkerPool($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\WorkerPool::class); - $this->worker_pool = $var; - - return $this; - } - - /** - * A mask specifying which fields in `worker_pool` to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * A mask specifying which fields in `worker_pool` to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the response, but do not actually - * post it. - * - * Generated from protobuf field bool validate_only = 4; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedMavenArtifact.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedMavenArtifact.php deleted file mode 100644 index 8b113b2b4450..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedMavenArtifact.php +++ /dev/null @@ -1,155 +0,0 @@ -google.devtools.cloudbuild.v1.UploadedMavenArtifact - */ -class UploadedMavenArtifact extends \Google\Protobuf\Internal\Message -{ - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Hash types and values of the Maven Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - */ - protected $file_hashes = null; - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $push_timing = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * URI of the uploaded artifact. - * @type \Google\Cloud\Build\V1\FileHashes $file_hashes - * Hash types and values of the Maven Artifact. - * @type \Google\Cloud\Build\V1\TimeSpan $push_timing - * Output only. Stores timing information for pushing the specified artifact. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Hash types and values of the Maven Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @return \Google\Cloud\Build\V1\FileHashes|null - */ - public function getFileHashes() - { - return $this->file_hashes; - } - - public function hasFileHashes() - { - return isset($this->file_hashes); - } - - public function clearFileHashes() - { - unset($this->file_hashes); - } - - /** - * Hash types and values of the Maven Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @param \Google\Cloud\Build\V1\FileHashes $var - * @return $this - */ - public function setFileHashes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\FileHashes::class); - $this->file_hashes = $var; - - return $this; - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getPushTiming() - { - return $this->push_timing; - } - - public function hasPushTiming() - { - return isset($this->push_timing); - } - - public function clearPushTiming() - { - unset($this->push_timing); - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setPushTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->push_timing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedNpmPackage.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedNpmPackage.php deleted file mode 100644 index d290c31a67d0..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedNpmPackage.php +++ /dev/null @@ -1,156 +0,0 @@ -google.devtools.cloudbuild.v1.UploadedNpmPackage - */ -class UploadedNpmPackage extends \Google\Protobuf\Internal\Message -{ - /** - * URI of the uploaded npm package. - * - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Hash types and values of the npm package. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - */ - protected $file_hashes = null; - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $push_timing = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * URI of the uploaded npm package. - * @type \Google\Cloud\Build\V1\FileHashes $file_hashes - * Hash types and values of the npm package. - * @type \Google\Cloud\Build\V1\TimeSpan $push_timing - * Output only. Stores timing information for pushing the specified artifact. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * URI of the uploaded npm package. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * URI of the uploaded npm package. - * - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Hash types and values of the npm package. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @return \Google\Cloud\Build\V1\FileHashes|null - */ - public function getFileHashes() - { - return $this->file_hashes; - } - - public function hasFileHashes() - { - return isset($this->file_hashes); - } - - public function clearFileHashes() - { - unset($this->file_hashes); - } - - /** - * Hash types and values of the npm package. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @param \Google\Cloud\Build\V1\FileHashes $var - * @return $this - */ - public function setFileHashes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\FileHashes::class); - $this->file_hashes = $var; - - return $this; - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getPushTiming() - { - return $this->push_timing; - } - - public function hasPushTiming() - { - return isset($this->push_timing); - } - - public function clearPushTiming() - { - unset($this->push_timing); - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setPushTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->push_timing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedPythonPackage.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedPythonPackage.php deleted file mode 100644 index 6aef89fae91b..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/UploadedPythonPackage.php +++ /dev/null @@ -1,155 +0,0 @@ -google.devtools.cloudbuild.v1.UploadedPythonPackage - */ -class UploadedPythonPackage extends \Google\Protobuf\Internal\Message -{ - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * Hash types and values of the Python Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - */ - protected $file_hashes = null; - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $push_timing = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * URI of the uploaded artifact. - * @type \Google\Cloud\Build\V1\FileHashes $file_hashes - * Hash types and values of the Python Artifact. - * @type \Google\Cloud\Build\V1\TimeSpan $push_timing - * Output only. Stores timing information for pushing the specified artifact. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * URI of the uploaded artifact. - * - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Hash types and values of the Python Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @return \Google\Cloud\Build\V1\FileHashes|null - */ - public function getFileHashes() - { - return $this->file_hashes; - } - - public function hasFileHashes() - { - return isset($this->file_hashes); - } - - public function clearFileHashes() - { - unset($this->file_hashes); - } - - /** - * Hash types and values of the Python Artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.FileHashes file_hashes = 2; - * @param \Google\Cloud\Build\V1\FileHashes $var - * @return $this - */ - public function setFileHashes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\FileHashes::class); - $this->file_hashes = $var; - - return $this; - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V1\TimeSpan|null - */ - public function getPushTiming() - { - return $this->push_timing; - } - - public function hasPushTiming() - { - return isset($this->push_timing); - } - - public function clearPushTiming() - { - unset($this->push_timing); - } - - /** - * Output only. Stores timing information for pushing the specified artifact. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.TimeSpan push_timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V1\TimeSpan $var - * @return $this - */ - public function setPushTiming($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\TimeSpan::class); - $this->push_timing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Volume.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Volume.php deleted file mode 100644 index a6b61b1398e2..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/Volume.php +++ /dev/null @@ -1,118 +0,0 @@ -google.devtools.cloudbuild.v1.Volume - */ -class Volume extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the volume to mount. - * Volume names must be unique per build step and must be valid names for - * Docker volumes. Each named volume must be used by at least two build steps. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Path at which to mount the volume. - * Paths must be absolute and cannot conflict with other volume paths on the - * same build step or with certain reserved volume paths. - * - * Generated from protobuf field string path = 2; - */ - protected $path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the volume to mount. - * Volume names must be unique per build step and must be valid names for - * Docker volumes. Each named volume must be used by at least two build steps. - * @type string $path - * Path at which to mount the volume. - * Paths must be absolute and cannot conflict with other volume paths on the - * same build step or with certain reserved volume paths. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Name of the volume to mount. - * Volume names must be unique per build step and must be valid names for - * Docker volumes. Each named volume must be used by at least two build steps. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the volume to mount. - * Volume names must be unique per build step and must be valid names for - * Docker volumes. Each named volume must be used by at least two build steps. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Path at which to mount the volume. - * Paths must be absolute and cannot conflict with other volume paths on the - * same build step or with certain reserved volume paths. - * - * Generated from protobuf field string path = 2; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * Path at which to mount the volume. - * Paths must be absolute and cannot conflict with other volume paths on the - * same build step or with certain reserved volume paths. - * - * Generated from protobuf field string path = 2; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig.php deleted file mode 100644 index 8d12ccb62112..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig.php +++ /dev/null @@ -1,114 +0,0 @@ -google.devtools.cloudbuild.v1.WebhookConfig - */ -class WebhookConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - */ - protected $state = 0; - protected $auth_method; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $secret - * Required. Resource name for the secret required as a URL parameter. - * @type int $state - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name for the secret required as a URL parameter. - * - * Generated from protobuf field string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getSecret() - { - return $this->readOneof(3); - } - - public function hasSecret() - { - return $this->hasOneof(3); - } - - /** - * Required. Resource name for the secret required as a URL parameter. - * - * Generated from protobuf field string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setSecret($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Potential issues with the underlying Pub/Sub subscription configuration. - * Only populated on get requests. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\WebhookConfig\State::class); - $this->state = $var; - - return $this; - } - - /** - * @return string - */ - public function getAuthMethod() - { - return $this->whichOneof("auth_method"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig/State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig/State.php deleted file mode 100644 index 16943727e632..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig/State.php +++ /dev/null @@ -1,65 +0,0 @@ -google.devtools.cloudbuild.v1.WebhookConfig.State - */ -class State -{ - /** - * The webhook auth configuration not been checked. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The auth configuration is properly setup. - * - * Generated from protobuf enum OK = 1; - */ - const OK = 1; - /** - * The secret provided in auth_method has been deleted. - * - * Generated from protobuf enum SECRET_DELETED = 2; - */ - const SECRET_DELETED = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::OK => 'OK', - self::SECRET_DELETED => 'SECRET_DELETED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Build\V1\WebhookConfig_State::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig_State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig_State.php deleted file mode 100644 index 20c2ba11299d..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WebhookConfig_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v1.WorkerPool - */ -class WorkerPool extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the `WorkerPool`, with format - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * The value of `{worker_pool}` is provided by `worker_pool_id` in - * `CreateWorkerPool` request and the value of `{location}` is determined by - * the endpoint accessed. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * A user-specified, human-readable name for the `WorkerPool`. If provided, - * this value must be 1-63 characters. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * Output only. A unique identifier for the `WorkerPool`. - * - * Generated from protobuf field string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * User specified annotations. See https://google.aip.dev/128#annotations - * for more details such as format and size limitations. - * - * Generated from protobuf field map annotations = 4; - */ - private $annotations; - /** - * Output only. Time at which the request to create the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Time at which the request to update the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Time at which the request to delete the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. `WorkerPool` state. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Checksum computed by the server. May be sent on update and - * delete requests to ensure that the client has an up-to-date value before - * proceeding. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $etag = ''; - protected $config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the `WorkerPool`, with format - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * The value of `{worker_pool}` is provided by `worker_pool_id` in - * `CreateWorkerPool` request and the value of `{location}` is determined by - * the endpoint accessed. - * @type string $display_name - * A user-specified, human-readable name for the `WorkerPool`. If provided, - * this value must be 1-63 characters. - * @type string $uid - * Output only. A unique identifier for the `WorkerPool`. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * User specified annotations. See https://google.aip.dev/128#annotations - * for more details such as format and size limitations. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Time at which the request to create the `WorkerPool` was - * received. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Time at which the request to update the `WorkerPool` was - * received. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. Time at which the request to delete the `WorkerPool` was - * received. - * @type int $state - * Output only. `WorkerPool` state. - * @type \Google\Cloud\Build\V1\PrivatePoolV1Config $private_pool_v1_config - * Legacy Private Pool configuration. - * @type string $etag - * Output only. Checksum computed by the server. May be sent on update and - * delete requests to ensure that the client has an up-to-date value before - * proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V1\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the `WorkerPool`, with format - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * The value of `{worker_pool}` is provided by `worker_pool_id` in - * `CreateWorkerPool` request and the value of `{location}` is determined by - * the endpoint accessed. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the `WorkerPool`, with format - * `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - * The value of `{worker_pool}` is provided by `worker_pool_id` in - * `CreateWorkerPool` request and the value of `{location}` is determined by - * the endpoint accessed. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A user-specified, human-readable name for the `WorkerPool`. If provided, - * this value must be 1-63 characters. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * A user-specified, human-readable name for the `WorkerPool`. If provided, - * this value must be 1-63 characters. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. A unique identifier for the `WorkerPool`. - * - * Generated from protobuf field string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. A unique identifier for the `WorkerPool`. - * - * Generated from protobuf field string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * User specified annotations. See https://google.aip.dev/128#annotations - * for more details such as format and size limitations. - * - * Generated from protobuf field map annotations = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * User specified annotations. See https://google.aip.dev/128#annotations - * for more details such as format and size limitations. - * - * Generated from protobuf field map annotations = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - - /** - * Output only. Time at which the request to create the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Time at which the request to create the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Time at which the request to update the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Time at which the request to update the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. Time at which the request to delete the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getDeleteTime() - { - return $this->delete_time; - } - - public function hasDeleteTime() - { - return isset($this->delete_time); - } - - public function clearDeleteTime() - { - unset($this->delete_time); - } - - /** - * Output only. Time at which the request to delete the `WorkerPool` was - * received. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setDeleteTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->delete_time = $var; - - return $this; - } - - /** - * Output only. `WorkerPool` state. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. `WorkerPool` state. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V1\WorkerPool\State::class); - $this->state = $var; - - return $this; - } - - /** - * Legacy Private Pool configuration. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * @return \Google\Cloud\Build\V1\PrivatePoolV1Config|null - */ - public function getPrivatePoolV1Config() - { - return $this->readOneof(12); - } - - public function hasPrivatePoolV1Config() - { - return $this->hasOneof(12); - } - - /** - * Legacy Private Pool configuration. - * - * Generated from protobuf field .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * @param \Google\Cloud\Build\V1\PrivatePoolV1Config $var - * @return $this - */ - public function setPrivatePoolV1Config($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V1\PrivatePoolV1Config::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * Output only. Checksum computed by the server. May be sent on update and - * delete requests to ensure that the client has an up-to-date value before - * proceeding. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Output only. Checksum computed by the server. May be sent on update and - * delete requests to ensure that the client has an up-to-date value before - * proceeding. - * - * Generated from protobuf field string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * @return string - */ - public function getConfig() - { - return $this->whichOneof("config"); - } - -} - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool/State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool/State.php deleted file mode 100644 index 77bd626c4c28..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool/State.php +++ /dev/null @@ -1,78 +0,0 @@ -google.devtools.cloudbuild.v1.WorkerPool.State - */ -class State -{ - /** - * State of the `WorkerPool` is unknown. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * `WorkerPool` is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * `WorkerPool` is running. - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * `WorkerPool` is being deleted: cancelling builds and draining workers. - * - * Generated from protobuf enum DELETING = 3; - */ - const DELETING = 3; - /** - * `WorkerPool` is deleted. - * - * Generated from protobuf enum DELETED = 4; - */ - const DELETED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::RUNNING => 'RUNNING', - self::DELETING => 'DELETING', - self::DELETED => 'DELETED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\Build\V1\WorkerPool_State::class); - diff --git a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool_State.php b/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool_State.php deleted file mode 100644 index 58a7bbf7e531..000000000000 --- a/owl-bot-staging/Build/v1/proto/src/Google/Cloud/Build/V1/WorkerPool_State.php +++ /dev/null @@ -1,16 +0,0 @@ -approveBuild($name); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Build $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 -{ - $name = '[NAME]'; - - approve_build_sample($name); -} -// [END cloudbuild_v1_generated_CloudBuild_ApproveBuild_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/cancel_build.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/cancel_build.php deleted file mode 100644 index 40f1c9827781..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/cancel_build.php +++ /dev/null @@ -1,67 +0,0 @@ -cancelBuild($projectId, $id); - 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 -{ - $projectId = '[PROJECT_ID]'; - $id = '[ID]'; - - cancel_build_sample($projectId, $id); -} -// [END cloudbuild_v1_generated_CloudBuild_CancelBuild_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build.php deleted file mode 100644 index 17512951da9a..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build.php +++ /dev/null @@ -1,84 +0,0 @@ -createBuild($projectId, $build); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Build $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 -{ - $projectId = '[PROJECT_ID]'; - - create_build_sample($projectId); -} -// [END cloudbuild_v1_generated_CloudBuild_CreateBuild_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build_trigger.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build_trigger.php deleted file mode 100644 index 2a59c5970bca..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_build_trigger.php +++ /dev/null @@ -1,70 +0,0 @@ -createBuildTrigger($projectId, $trigger); - 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 -{ - $projectId = '[PROJECT_ID]'; - - create_build_trigger_sample($projectId); -} -// [END cloudbuild_v1_generated_CloudBuild_CreateBuildTrigger_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_worker_pool.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_worker_pool.php deleted file mode 100644 index 3233a8ae4c22..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/create_worker_pool.php +++ /dev/null @@ -1,88 +0,0 @@ -createWorkerPool($formattedParent, $workerPool, $workerPoolId); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var WorkerPool $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 = CloudBuildClient::locationName('[PROJECT]', '[LOCATION]'); - $workerPoolId = '[WORKER_POOL_ID]'; - - create_worker_pool_sample($formattedParent, $workerPoolId); -} -// [END cloudbuild_v1_generated_CloudBuild_CreateWorkerPool_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_build_trigger.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_build_trigger.php deleted file mode 100644 index d201f17eacab..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_build_trigger.php +++ /dev/null @@ -1,67 +0,0 @@ -deleteBuildTrigger($projectId, $triggerId); - 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 -{ - $projectId = '[PROJECT_ID]'; - $triggerId = '[TRIGGER_ID]'; - - delete_build_trigger_sample($projectId, $triggerId); -} -// [END cloudbuild_v1_generated_CloudBuild_DeleteBuildTrigger_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_worker_pool.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_worker_pool.php deleted file mode 100644 index 38e69a251d84..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/delete_worker_pool.php +++ /dev/null @@ -1,77 +0,0 @@ -deleteWorkerPool($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 = CloudBuildClient::workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - - delete_worker_pool_sample($formattedName); -} -// [END cloudbuild_v1_generated_CloudBuild_DeleteWorkerPool_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build.php deleted file mode 100644 index 1d034df6f087..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build.php +++ /dev/null @@ -1,70 +0,0 @@ -getBuild($projectId, $id); - 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 -{ - $projectId = '[PROJECT_ID]'; - $id = '[ID]'; - - get_build_sample($projectId, $id); -} -// [END cloudbuild_v1_generated_CloudBuild_GetBuild_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build_trigger.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build_trigger.php deleted file mode 100644 index f9691484ceb7..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_build_trigger.php +++ /dev/null @@ -1,69 +0,0 @@ -getBuildTrigger($projectId, $triggerId); - 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 -{ - $projectId = '[PROJECT_ID]'; - $triggerId = '[TRIGGER_ID]'; - - get_build_trigger_sample($projectId, $triggerId); -} -// [END cloudbuild_v1_generated_CloudBuild_GetBuildTrigger_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_worker_pool.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_worker_pool.php deleted file mode 100644 index b473337fa831..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/get_worker_pool.php +++ /dev/null @@ -1,67 +0,0 @@ -getWorkerPool($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 = CloudBuildClient::workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - - get_worker_pool_sample($formattedName); -} -// [END cloudbuild_v1_generated_CloudBuild_GetWorkerPool_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_build_triggers.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_build_triggers.php deleted file mode 100644 index a36010011aa0..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_build_triggers.php +++ /dev/null @@ -1,72 +0,0 @@ -listBuildTriggers($projectId); - - /** @var BuildTrigger $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 -{ - $projectId = '[PROJECT_ID]'; - - list_build_triggers_sample($projectId); -} -// [END cloudbuild_v1_generated_CloudBuild_ListBuildTriggers_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_builds.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_builds.php deleted file mode 100644 index 6c81d0f4060d..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_builds.php +++ /dev/null @@ -1,73 +0,0 @@ -listBuilds($projectId); - - /** @var Build $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 -{ - $projectId = '[PROJECT_ID]'; - - list_builds_sample($projectId); -} -// [END cloudbuild_v1_generated_CloudBuild_ListBuilds_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_worker_pools.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_worker_pools.php deleted file mode 100644 index 35bbabd4655d..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/list_worker_pools.php +++ /dev/null @@ -1,72 +0,0 @@ -listWorkerPools($formattedParent); - - /** @var WorkerPool $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 = CloudBuildClient::locationName('[PROJECT]', '[LOCATION]'); - - list_worker_pools_sample($formattedParent); -} -// [END cloudbuild_v1_generated_CloudBuild_ListWorkerPools_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/receive_trigger_webhook.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/receive_trigger_webhook.php deleted file mode 100644 index f25def1e309e..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/receive_trigger_webhook.php +++ /dev/null @@ -1,54 +0,0 @@ -receiveTriggerWebhook(); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END cloudbuild_v1_generated_CloudBuild_ReceiveTriggerWebhook_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/retry_build.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/retry_build.php deleted file mode 100644 index 72fe9530dca3..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/retry_build.php +++ /dev/null @@ -1,105 +0,0 @@ -retryBuild($projectId, $id); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Build $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 -{ - $projectId = '[PROJECT_ID]'; - $id = '[ID]'; - - retry_build_sample($projectId, $id); -} -// [END cloudbuild_v1_generated_CloudBuild_RetryBuild_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/run_build_trigger.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/run_build_trigger.php deleted file mode 100644 index 8f7d0009ae32..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/run_build_trigger.php +++ /dev/null @@ -1,79 +0,0 @@ -runBuildTrigger($projectId, $triggerId); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Build $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 -{ - $projectId = '[PROJECT_ID]'; - $triggerId = '[TRIGGER_ID]'; - - run_build_trigger_sample($projectId, $triggerId); -} -// [END cloudbuild_v1_generated_CloudBuild_RunBuildTrigger_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_build_trigger.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_build_trigger.php deleted file mode 100644 index 96d21b0c3b32..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_build_trigger.php +++ /dev/null @@ -1,72 +0,0 @@ -updateBuildTrigger($projectId, $triggerId, $trigger); - 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 -{ - $projectId = '[PROJECT_ID]'; - $triggerId = '[TRIGGER_ID]'; - - update_build_trigger_sample($projectId, $triggerId); -} -// [END cloudbuild_v1_generated_CloudBuild_UpdateBuildTrigger_sync] diff --git a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_worker_pool.php b/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_worker_pool.php deleted file mode 100644 index 506c57341265..000000000000 --- a/owl-bot-staging/Build/v1/samples/V1/CloudBuildClient/update_worker_pool.php +++ /dev/null @@ -1,68 +0,0 @@ -updateWorkerPool($workerPool); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var WorkerPool $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 cloudbuild_v1_generated_CloudBuild_UpdateWorkerPool_sync] diff --git a/owl-bot-staging/Build/v1/src/V1/CloudBuildClient.php b/owl-bot-staging/Build/v1/src/V1/CloudBuildClient.php deleted file mode 100644 index 2238a58864a4..000000000000 --- a/owl-bot-staging/Build/v1/src/V1/CloudBuildClient.php +++ /dev/null @@ -1,34 +0,0 @@ -approveBuild($name); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->approveBuild($name); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'approveBuild'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * 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. - */ -class CloudBuildGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.devtools.cloudbuild.v1.CloudBuild'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'cloudbuild.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $buildNameTemplate; - - private static $buildTriggerNameTemplate; - - private static $cryptoKeyNameTemplate; - - private static $locationNameTemplate; - - private static $networkNameTemplate; - - private static $projectNameTemplate; - - private static $projectBuildNameTemplate; - - private static $projectLocationBuildNameTemplate; - - private static $projectLocationTriggerNameTemplate; - - private static $projectTriggerNameTemplate; - - private static $secretVersionNameTemplate; - - private static $serviceAccountNameTemplate; - - private static $subscriptionNameTemplate; - - private static $topicNameTemplate; - - private static $workerPoolNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/cloud_build_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/cloud_build_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/cloud_build_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/cloud_build_rest_client_config.php', - ], - ], - ]; - } - - private static function getBuildNameTemplate() - { - if (self::$buildNameTemplate == null) { - self::$buildNameTemplate = new PathTemplate('projects/{project}/builds/{build}'); - } - - return self::$buildNameTemplate; - } - - private static function getBuildTriggerNameTemplate() - { - if (self::$buildTriggerNameTemplate == null) { - self::$buildTriggerNameTemplate = new PathTemplate('projects/{project}/triggers/{trigger}'); - } - - return self::$buildTriggerNameTemplate; - } - - private static function getCryptoKeyNameTemplate() - { - if (self::$cryptoKeyNameTemplate == null) { - self::$cryptoKeyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}'); - } - - return self::$cryptoKeyNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getNetworkNameTemplate() - { - if (self::$networkNameTemplate == null) { - self::$networkNameTemplate = new PathTemplate('projects/{project}/global/networks/{network}'); - } - - return self::$networkNameTemplate; - } - - private static function getProjectNameTemplate() - { - if (self::$projectNameTemplate == null) { - self::$projectNameTemplate = new PathTemplate('projects/{project}'); - } - - return self::$projectNameTemplate; - } - - private static function getProjectBuildNameTemplate() - { - if (self::$projectBuildNameTemplate == null) { - self::$projectBuildNameTemplate = new PathTemplate('projects/{project}/builds/{build}'); - } - - return self::$projectBuildNameTemplate; - } - - private static function getProjectLocationBuildNameTemplate() - { - if (self::$projectLocationBuildNameTemplate == null) { - self::$projectLocationBuildNameTemplate = new PathTemplate('projects/{project}/locations/{location}/builds/{build}'); - } - - return self::$projectLocationBuildNameTemplate; - } - - private static function getProjectLocationTriggerNameTemplate() - { - if (self::$projectLocationTriggerNameTemplate == null) { - self::$projectLocationTriggerNameTemplate = new PathTemplate('projects/{project}/locations/{location}/triggers/{trigger}'); - } - - return self::$projectLocationTriggerNameTemplate; - } - - private static function getProjectTriggerNameTemplate() - { - if (self::$projectTriggerNameTemplate == null) { - self::$projectTriggerNameTemplate = new PathTemplate('projects/{project}/triggers/{trigger}'); - } - - return self::$projectTriggerNameTemplate; - } - - private static function getSecretVersionNameTemplate() - { - if (self::$secretVersionNameTemplate == null) { - self::$secretVersionNameTemplate = new PathTemplate('projects/{project}/secrets/{secret}/versions/{version}'); - } - - return self::$secretVersionNameTemplate; - } - - private static function getServiceAccountNameTemplate() - { - if (self::$serviceAccountNameTemplate == null) { - self::$serviceAccountNameTemplate = new PathTemplate('projects/{project}/serviceAccounts/{service_account}'); - } - - return self::$serviceAccountNameTemplate; - } - - private static function getSubscriptionNameTemplate() - { - if (self::$subscriptionNameTemplate == null) { - self::$subscriptionNameTemplate = new PathTemplate('projects/{project}/subscriptions/{subscription}'); - } - - return self::$subscriptionNameTemplate; - } - - private static function getTopicNameTemplate() - { - if (self::$topicNameTemplate == null) { - self::$topicNameTemplate = new PathTemplate('projects/{project}/topics/{topic}'); - } - - return self::$topicNameTemplate; - } - - private static function getWorkerPoolNameTemplate() - { - if (self::$workerPoolNameTemplate == null) { - self::$workerPoolNameTemplate = new PathTemplate('projects/{project}/locations/{location}/workerPools/{worker_pool}'); - } - - return self::$workerPoolNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'build' => self::getBuildNameTemplate(), - 'buildTrigger' => self::getBuildTriggerNameTemplate(), - 'cryptoKey' => self::getCryptoKeyNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'network' => self::getNetworkNameTemplate(), - 'project' => self::getProjectNameTemplate(), - 'projectBuild' => self::getProjectBuildNameTemplate(), - 'projectLocationBuild' => self::getProjectLocationBuildNameTemplate(), - 'projectLocationTrigger' => self::getProjectLocationTriggerNameTemplate(), - 'projectTrigger' => self::getProjectTriggerNameTemplate(), - 'secretVersion' => self::getSecretVersionNameTemplate(), - 'serviceAccount' => self::getServiceAccountNameTemplate(), - 'subscription' => self::getSubscriptionNameTemplate(), - 'topic' => self::getTopicNameTemplate(), - 'workerPool' => self::getWorkerPoolNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a build - * resource. - * - * @param string $project - * @param string $build - * - * @return string The formatted build resource. - */ - public static function buildName($project, $build) - { - return self::getBuildNameTemplate()->render([ - 'project' => $project, - 'build' => $build, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * build_trigger resource. - * - * @param string $project - * @param string $trigger - * - * @return string The formatted build_trigger resource. - */ - public static function buildTriggerName($project, $trigger) - { - return self::getBuildTriggerNameTemplate()->render([ - 'project' => $project, - 'trigger' => $trigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a crypto_key - * resource. - * - * @param string $project - * @param string $location - * @param string $keyring - * @param string $key - * - * @return string The formatted crypto_key resource. - */ - public static function cryptoKeyName($project, $location, $keyring, $key) - { - return self::getCryptoKeyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'keyring' => $keyring, - 'key' => $key, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a network - * resource. - * - * @param string $project - * @param string $network - * - * @return string The formatted network resource. - */ - public static function networkName($project, $network) - { - return self::getNetworkNameTemplate()->render([ - 'project' => $project, - 'network' => $network, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - */ - public static function projectName($project) - { - return self::getProjectNameTemplate()->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_build resource. - * - * @param string $project - * @param string $build - * - * @return string The formatted project_build resource. - */ - public static function projectBuildName($project, $build) - { - return self::getProjectBuildNameTemplate()->render([ - 'project' => $project, - 'build' => $build, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_build resource. - * - * @param string $project - * @param string $location - * @param string $build - * - * @return string The formatted project_location_build resource. - */ - public static function projectLocationBuildName($project, $location, $build) - { - return self::getProjectLocationBuildNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'build' => $build, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_trigger resource. - * - * @param string $project - * @param string $location - * @param string $trigger - * - * @return string The formatted project_location_trigger resource. - */ - public static function projectLocationTriggerName($project, $location, $trigger) - { - return self::getProjectLocationTriggerNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'trigger' => $trigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_trigger resource. - * - * @param string $project - * @param string $trigger - * - * @return string The formatted project_trigger resource. - */ - public static function projectTriggerName($project, $trigger) - { - return self::getProjectTriggerNameTemplate()->render([ - 'project' => $project, - 'trigger' => $trigger, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * secret_version resource. - * - * @param string $project - * @param string $secret - * @param string $version - * - * @return string The formatted secret_version resource. - */ - public static function secretVersionName($project, $secret, $version) - { - return self::getSecretVersionNameTemplate()->render([ - 'project' => $project, - 'secret' => $secret, - 'version' => $version, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * service_account resource. - * - * @param string $project - * @param string $serviceAccount - * - * @return string The formatted service_account resource. - */ - public static function serviceAccountName($project, $serviceAccount) - { - return self::getServiceAccountNameTemplate()->render([ - 'project' => $project, - 'service_account' => $serviceAccount, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a subscription - * resource. - * - * @param string $project - * @param string $subscription - * - * @return string The formatted subscription resource. - */ - public static function subscriptionName($project, $subscription) - { - return self::getSubscriptionNameTemplate()->render([ - 'project' => $project, - 'subscription' => $subscription, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a topic - * resource. - * - * @param string $project - * @param string $topic - * - * @return string The formatted topic resource. - */ - public static function topicName($project, $topic) - { - return self::getTopicNameTemplate()->render([ - 'project' => $project, - 'topic' => $topic, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a worker_pool - * resource. - * - * @param string $project - * @param string $location - * @param string $workerPool - * - * @return string The formatted worker_pool resource. - */ - public static function workerPoolName($project, $location, $workerPool) - { - return self::getWorkerPoolNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'worker_pool' => $workerPool, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - build: projects/{project}/builds/{build} - * - buildTrigger: projects/{project}/triggers/{trigger} - * - cryptoKey: projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key} - * - location: projects/{project}/locations/{location} - * - network: projects/{project}/global/networks/{network} - * - project: projects/{project} - * - projectBuild: projects/{project}/builds/{build} - * - projectLocationBuild: projects/{project}/locations/{location}/builds/{build} - * - projectLocationTrigger: projects/{project}/locations/{location}/triggers/{trigger} - * - projectTrigger: projects/{project}/triggers/{trigger} - * - secretVersion: projects/{project}/secrets/{secret}/versions/{version} - * - serviceAccount: projects/{project}/serviceAccounts/{service_account} - * - subscription: projects/{project}/subscriptions/{subscription} - * - topic: projects/{project}/topics/{topic} - * - workerPool: projects/{project}/locations/{location}/workerPools/{worker_pool} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'cloudbuild.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Approves or rejects a pending build. - * - * If approved, the returned LRO will be analogous to the LRO returned from - * a CreateBuild call. - * - * If rejected, the returned LRO will be immediately done. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $name = 'name'; - * $operationResponse = $cloudBuildClient->approveBuild($name); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->approveBuild($name); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'approveBuild'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the target build. - * For example: "projects/{$project_id}/builds/{$build_id}" - * @param array $optionalArgs { - * Optional. - * - * @type ApprovalResult $approvalResult - * Approval decision and metadata. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function approveBuild($name, array $optionalArgs = []) - { - $request = new ApproveBuildRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['approvalResult'])) { - $request->setApprovalResult($optionalArgs['approvalResult']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('ApproveBuild', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Cancels a build in progress. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $id = 'id'; - * $response = $cloudBuildClient->cancelBuild($projectId, $id); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param string $id Required. ID of the build. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Build` to cancel. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\Build - * - * @throws ApiException if the remote call fails - */ - public function cancelBuild($projectId, $id, array $optionalArgs = []) - { - $request = new CancelBuildRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setId($id); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['id'] = $id; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CancelBuild', Build::class, $optionalArgs, $request)->wait(); - } - - /** - * Starts a build with the specified configuration. - * - * This method returns a long-running `Operation`, which includes the build - * ID. Pass the build ID to `GetBuild` to determine the build status (such as - * `SUCCESS` or `FAILURE`). - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $build = new Build(); - * $operationResponse = $cloudBuildClient->createBuild($projectId, $build); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->createBuild($projectId, $build); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'createBuild'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param Build $build Required. Build resource to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * The parent resource where this build will be created. - * Format: `projects/{project}/locations/{location}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createBuild($projectId, $build, array $optionalArgs = []) - { - $request = new CreateBuildRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setBuild($build); - $requestParamHeaders['project_id'] = $projectId; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateBuild', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new `BuildTrigger`. - * - * This API is experimental. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $trigger = new BuildTrigger(); - * $response = $cloudBuildClient->createBuildTrigger($projectId, $trigger); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project for which to configure automatic builds. - * @param BuildTrigger $trigger Required. `BuildTrigger` to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * The parent resource where this trigger will be created. - * Format: `projects/{project}/locations/{location}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\BuildTrigger - * - * @throws ApiException if the remote call fails - */ - public function createBuildTrigger($projectId, $trigger, array $optionalArgs = []) - { - $request = new CreateBuildTriggerRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setTrigger($trigger); - $requestParamHeaders['project_id'] = $projectId; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateBuildTrigger', BuildTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a `WorkerPool`. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $formattedParent = $cloudBuildClient->locationName('[PROJECT]', '[LOCATION]'); - * $workerPool = new WorkerPool(); - * $workerPoolId = 'worker_pool_id'; - * $operationResponse = $cloudBuildClient->createWorkerPool($formattedParent, $workerPool, $workerPoolId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->createWorkerPool($formattedParent, $workerPool, $workerPoolId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'createWorkerPool'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource where this worker pool will be created. - * Format: `projects/{project}/locations/{location}`. - * @param WorkerPool $workerPool Required. `WorkerPool` resource to create. - * @param string $workerPoolId Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - * - * This value should be 1-63 characters, and valid characters - * are /[a-z][0-9]-/. - * @param array $optionalArgs { - * Optional. - * - * @type bool $validateOnly - * If set, validate the request and preview the response, but do not actually - * post it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createWorkerPool($parent, $workerPool, $workerPoolId, array $optionalArgs = []) - { - $request = new CreateWorkerPoolRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setWorkerPool($workerPool); - $request->setWorkerPoolId($workerPoolId); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateWorkerPool', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a `BuildTrigger` by its project ID and trigger ID. - * - * This API is experimental. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $triggerId = 'trigger_id'; - * $cloudBuildClient->deleteBuildTrigger($projectId, $triggerId); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project that owns the trigger. - * @param string $triggerId Required. ID of the `BuildTrigger` to delete. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Trigger` to delete. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteBuildTrigger($projectId, $triggerId, array $optionalArgs = []) - { - $request = new DeleteBuildTriggerRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setTriggerId($triggerId); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['trigger_id'] = $triggerId; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteBuildTrigger', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a `WorkerPool`. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $formattedName = $cloudBuildClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - * $operationResponse = $cloudBuildClient->deleteWorkerPool($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->deleteWorkerPool($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'deleteWorkerPool'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the `WorkerPool` to delete. - * Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @param array $optionalArgs { - * Optional. - * - * @type string $etag - * Optional. If this is provided, it must match the server's etag on the - * workerpool for the request to be processed. - * @type bool $allowMissing - * If set to true, and the `WorkerPool` is not found, the request will succeed - * but no action will be taken on the server. - * @type bool $validateOnly - * If set, validate the request and preview the response, but do not actually - * post it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteWorkerPool($name, array $optionalArgs = []) - { - $request = new DeleteWorkerPoolRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['etag'])) { - $request->setEtag($optionalArgs['etag']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteWorkerPool', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Returns information about a previously requested build. - * - * The `Build` that is returned includes its status (such as `SUCCESS`, - * `FAILURE`, or `WORKING`), and timing information. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $id = 'id'; - * $response = $cloudBuildClient->getBuild($projectId, $id); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param string $id Required. ID of the build. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Build` to retrieve. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\Build - * - * @throws ApiException if the remote call fails - */ - public function getBuild($projectId, $id, array $optionalArgs = []) - { - $request = new GetBuildRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setId($id); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['id'] = $id; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetBuild', Build::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns information about a `BuildTrigger`. - * - * This API is experimental. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $triggerId = 'trigger_id'; - * $response = $cloudBuildClient->getBuildTrigger($projectId, $triggerId); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project that owns the trigger. - * @param string $triggerId Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Trigger` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\BuildTrigger - * - * @throws ApiException if the remote call fails - */ - public function getBuildTrigger($projectId, $triggerId, array $optionalArgs = []) - { - $request = new GetBuildTriggerRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setTriggerId($triggerId); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['trigger_id'] = $triggerId; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetBuildTrigger', BuildTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns details of a `WorkerPool`. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $formattedName = $cloudBuildClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - * $response = $cloudBuildClient->getWorkerPool($formattedName); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the `WorkerPool` to retrieve. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\WorkerPool - * - * @throws ApiException if the remote call fails - */ - public function getWorkerPool($name, array $optionalArgs = []) - { - $request = new GetWorkerPoolRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetWorkerPool', WorkerPool::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists existing `BuildTrigger`s. - * - * This API is experimental. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * // Iterate over pages of elements - * $pagedResponse = $cloudBuildClient->listBuildTriggers($projectId); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $cloudBuildClient->listBuildTriggers($projectId); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project for which to list BuildTriggers. - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * The parent of the collection of `Triggers`. - * Format: `projects/{project}/locations/{location}` - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listBuildTriggers($projectId, array $optionalArgs = []) - { - $request = new ListBuildTriggersRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $requestParamHeaders['project_id'] = $projectId; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListBuildTriggers', $optionalArgs, ListBuildTriggersResponse::class, $request); - } - - /** - * Lists previously requested builds. - * - * Previously requested builds may still be in-progress, or may have finished - * successfully or unsuccessfully. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * // Iterate over pages of elements - * $pagedResponse = $cloudBuildClient->listBuilds($projectId); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $cloudBuildClient->listBuilds($projectId); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param array $optionalArgs { - * Optional. - * - * @type string $parent - * The parent of the collection of `Builds`. - * Format: `projects/{project}/locations/{location}` - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * The raw filter text to constrain the results. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listBuilds($projectId, array $optionalArgs = []) - { - $request = new ListBuildsRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $requestParamHeaders['project_id'] = $projectId; - if (isset($optionalArgs['parent'])) { - $request->setParent($optionalArgs['parent']); - $requestParamHeaders['parent'] = $optionalArgs['parent']; - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListBuilds', $optionalArgs, ListBuildsResponse::class, $request); - } - - /** - * Lists `WorkerPool`s. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $formattedParent = $cloudBuildClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $cloudBuildClient->listWorkerPools($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $cloudBuildClient->listWorkerPools($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent of the collection of `WorkerPools`. - * Format: `projects/{project}/locations/{location}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listWorkerPools($parent, array $optionalArgs = []) - { - $request = new ListWorkerPoolsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListWorkerPools', $optionalArgs, ListWorkerPoolsResponse::class, $request); - } - - /** - * ReceiveTriggerWebhook [Experimental] is called when the API receives a - * webhook request targeted at a specific trigger. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $response = $cloudBuildClient->receiveTriggerWebhook(); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `ReceiveTriggerWebhook` to retrieve. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type HttpBody $body - * HTTP request body. - * @type string $projectId - * Project in which the specified trigger lives - * @type string $trigger - * Name of the trigger to run the payload against - * @type string $secret - * Secret token used for authorization if an OAuth token isn't provided. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\ReceiveTriggerWebhookResponse - * - * @throws ApiException if the remote call fails - */ - public function receiveTriggerWebhook(array $optionalArgs = []) - { - $request = new ReceiveTriggerWebhookRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['body'])) { - $request->setBody($optionalArgs['body']); - } - - if (isset($optionalArgs['projectId'])) { - $request->setProjectId($optionalArgs['projectId']); - $requestParamHeaders['project_id'] = $optionalArgs['projectId']; - } - - if (isset($optionalArgs['trigger'])) { - $request->setTrigger($optionalArgs['trigger']); - $requestParamHeaders['trigger'] = $optionalArgs['trigger']; - } - - if (isset($optionalArgs['secret'])) { - $request->setSecret($optionalArgs['secret']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('ReceiveTriggerWebhook', ReceiveTriggerWebhookResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new build based on the specified build. - * - * This method creates a new build using the original build request, which may - * or may not result in an identical build. - * - * For triggered builds: - * - * * Triggered builds resolve to a precise revision; therefore a retry of a - * triggered build will result in a build that uses the same revision. - * - * For non-triggered builds that specify `RepoSource`: - * - * * If the original build built from the tip of a branch, the retried build - * will build from the tip of that branch, which may not be the same revision - * as the original build. - * * If the original build specified a commit sha or revision ID, the retried - * build will use the identical source. - * - * For builds that specify `StorageSource`: - * - * * If the original build pulled source from Google Cloud Storage without - * specifying the generation of the object, the new build will use the current - * object, which may be different from the original build source. - * * If the original build pulled source from Cloud Storage and specified the - * generation of the object, the new build will attempt to use the same - * object, which may or may not be available depending on the bucket's - * lifecycle management settings. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $id = 'id'; - * $operationResponse = $cloudBuildClient->retryBuild($projectId, $id); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->retryBuild($projectId, $id); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'retryBuild'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param string $id Required. Build ID of the original build. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Build` to retry. - * Format: `projects/{project}/locations/{location}/builds/{build}` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function retryBuild($projectId, $id, array $optionalArgs = []) - { - $request = new RetryBuildRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setId($id); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['id'] = $id; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('RetryBuild', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Runs a `BuildTrigger` at a particular source revision. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $triggerId = 'trigger_id'; - * $operationResponse = $cloudBuildClient->runBuildTrigger($projectId, $triggerId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->runBuildTrigger($projectId, $triggerId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'runBuildTrigger'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project. - * @param string $triggerId Required. ID of the trigger. - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The name of the `Trigger` to run. - * Format: `projects/{project}/locations/{location}/triggers/{trigger}` - * @type RepoSource $source - * Source to build against this trigger. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function runBuildTrigger($projectId, $triggerId, array $optionalArgs = []) - { - $request = new RunBuildTriggerRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setTriggerId($triggerId); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['trigger_id'] = $triggerId; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['source'])) { - $request->setSource($optionalArgs['source']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('RunBuildTrigger', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates a `BuildTrigger` by its project ID and trigger ID. - * - * This API is experimental. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $projectId = 'project_id'; - * $triggerId = 'trigger_id'; - * $trigger = new BuildTrigger(); - * $response = $cloudBuildClient->updateBuildTrigger($projectId, $triggerId, $trigger); - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param string $projectId Required. ID of the project that owns the trigger. - * @param string $triggerId Required. ID of the `BuildTrigger` to update. - * @param BuildTrigger $trigger Required. `BuildTrigger` to update. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V1\BuildTrigger - * - * @throws ApiException if the remote call fails - */ - public function updateBuildTrigger($projectId, $triggerId, $trigger, array $optionalArgs = []) - { - $request = new UpdateBuildTriggerRequest(); - $requestParamHeaders = []; - $request->setProjectId($projectId); - $request->setTriggerId($triggerId); - $request->setTrigger($trigger); - $requestParamHeaders['project_id'] = $projectId; - $requestParamHeaders['trigger_id'] = $triggerId; - $requestParamHeaders['trigger.resource_name'] = $trigger->getResourceName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateBuildTrigger', BuildTrigger::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a `WorkerPool`. - * - * Sample code: - * ``` - * $cloudBuildClient = new CloudBuildClient(); - * try { - * $workerPool = new WorkerPool(); - * $operationResponse = $cloudBuildClient->updateWorkerPool($workerPool); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $cloudBuildClient->updateWorkerPool($workerPool); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $cloudBuildClient->resumeOperation($operationName, 'updateWorkerPool'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $cloudBuildClient->close(); - * } - * ``` - * - * @param WorkerPool $workerPool Required. The `WorkerPool` to update. - * - * The `name` field is used to identify the `WorkerPool` to update. - * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * A mask specifying which fields in `worker_pool` to update. - * @type bool $validateOnly - * If set, validate the request and preview the response, but do not actually - * post it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateWorkerPool($workerPool, array $optionalArgs = []) - { - $request = new UpdateWorkerPoolRequest(); - $requestParamHeaders = []; - $request->setWorkerPool($workerPool); - $requestParamHeaders['worker_pool.name'] = $workerPool->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateWorkerPool', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } -} diff --git a/owl-bot-staging/Build/v1/src/V1/gapic_metadata.json b/owl-bot-staging/Build/v1/src/V1/gapic_metadata.json deleted file mode 100644 index fbef7758f29a..000000000000 --- a/owl-bot-staging/Build/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,108 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.devtools.cloudbuild.v1", - "libraryPackage": "Google\\Cloud\\Build\\V1", - "services": { - "CloudBuild": { - "clients": { - "grpc": { - "libraryClient": "CloudBuildGapicClient", - "rpcs": { - "ApproveBuild": { - "methods": [ - "approveBuild" - ] - }, - "CancelBuild": { - "methods": [ - "cancelBuild" - ] - }, - "CreateBuild": { - "methods": [ - "createBuild" - ] - }, - "CreateBuildTrigger": { - "methods": [ - "createBuildTrigger" - ] - }, - "CreateWorkerPool": { - "methods": [ - "createWorkerPool" - ] - }, - "DeleteBuildTrigger": { - "methods": [ - "deleteBuildTrigger" - ] - }, - "DeleteWorkerPool": { - "methods": [ - "deleteWorkerPool" - ] - }, - "GetBuild": { - "methods": [ - "getBuild" - ] - }, - "GetBuildTrigger": { - "methods": [ - "getBuildTrigger" - ] - }, - "GetWorkerPool": { - "methods": [ - "getWorkerPool" - ] - }, - "ListBuildTriggers": { - "methods": [ - "listBuildTriggers" - ] - }, - "ListBuilds": { - "methods": [ - "listBuilds" - ] - }, - "ListWorkerPools": { - "methods": [ - "listWorkerPools" - ] - }, - "ReceiveTriggerWebhook": { - "methods": [ - "receiveTriggerWebhook" - ] - }, - "RetryBuild": { - "methods": [ - "retryBuild" - ] - }, - "RunBuildTrigger": { - "methods": [ - "runBuildTrigger" - ] - }, - "UpdateBuildTrigger": { - "methods": [ - "updateBuildTrigger" - ] - }, - "UpdateWorkerPool": { - "methods": [ - "updateWorkerPool" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_client_config.json b/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_client_config.json deleted file mode 100644 index 3ce3e39143c9..000000000000 --- a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_client_config.json +++ /dev/null @@ -1,116 +0,0 @@ -{ - "interfaces": { - "google.devtools.cloudbuild.v1.CloudBuild": { - "retry_codes": { - "idempotent": [ - "DEADLINE_EXCEEDED", - "UNAVAILABLE" - ], - "non_idempotent": [] - }, - "retry_params": { - "default": { - "initial_retry_delay_millis": 100, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 20000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 20000, - "total_timeout_millis": 600000 - } - }, - "methods": { - "ApproveBuild": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CancelBuild": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateBuild": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateBuildTrigger": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateWorkerPool": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteBuildTrigger": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteWorkerPool": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "GetBuild": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetBuildTrigger": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetWorkerPool": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListBuildTriggers": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListBuilds": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListWorkerPools": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ReceiveTriggerWebhook": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "RetryBuild": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "RunBuildTrigger": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateBuildTrigger": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateWorkerPool": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - } - } - } - } -} diff --git a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_descriptor_config.php b/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_descriptor_config.php deleted file mode 100644 index 4713c1b1f306..000000000000 --- a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_descriptor_config.php +++ /dev/null @@ -1,108 +0,0 @@ - [ - 'google.devtools.cloudbuild.v1.CloudBuild' => [ - 'ApproveBuild' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\Build', - 'metadataReturnType' => '\Google\Cloud\Build\V1\BuildOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateBuild' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\Build', - 'metadataReturnType' => '\Google\Cloud\Build\V1\BuildOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'CreateWorkerPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\WorkerPool', - 'metadataReturnType' => '\Google\Cloud\Build\V1\CreateWorkerPoolOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'DeleteWorkerPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Build\V1\DeleteWorkerPoolOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'RetryBuild' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\Build', - 'metadataReturnType' => '\Google\Cloud\Build\V1\BuildOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'RunBuildTrigger' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\Build', - 'metadataReturnType' => '\Google\Cloud\Build\V1\BuildOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'UpdateWorkerPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V1\WorkerPool', - 'metadataReturnType' => '\Google\Cloud\Build\V1\UpdateWorkerPoolOperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'ListBuildTriggers' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getTriggers', - ], - ], - 'ListBuilds' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getBuilds', - ], - ], - 'ListWorkerPools' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getWorkerPools', - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_rest_client_config.php b/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_rest_client_config.php deleted file mode 100644 index a8cd7478a2e0..000000000000 --- a/owl-bot-staging/Build/v1/src/V1/resources/cloud_build_rest_client_config.php +++ /dev/null @@ -1,445 +0,0 @@ - [ - 'google.devtools.cloudbuild.v1.CloudBuild' => [ - 'ApproveBuild' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/builds/*}:approve', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/builds/*}:approve', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'CancelBuild' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/builds/{id}:cancel', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/builds/*}:cancel', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'id' => [ - 'getters' => [ - 'getId', - ], - ], - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'CreateBuild' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/builds', - 'body' => 'build', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/builds', - 'body' => 'build', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'CreateBuildTrigger' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/triggers', - 'body' => 'trigger', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/triggers', - 'body' => 'trigger', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'CreateWorkerPool' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/workerPools', - 'body' => 'worker_pool', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'worker_pool_id', - ], - ], - 'DeleteBuildTrigger' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/projects/{project_id}/triggers/{trigger_id}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/triggers/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - 'trigger_id' => [ - 'getters' => [ - 'getTriggerId', - ], - ], - ], - ], - 'DeleteWorkerPool' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/workerPools/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetBuild' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/projects/{project_id}/builds/{id}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/builds/*}', - ], - ], - 'placeholders' => [ - 'id' => [ - 'getters' => [ - 'getId', - ], - ], - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'GetBuildTrigger' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/projects/{project_id}/triggers/{trigger_id}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/triggers/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - 'trigger_id' => [ - 'getters' => [ - 'getTriggerId', - ], - ], - ], - ], - 'GetWorkerPool' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/workerPools/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListBuildTriggers' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/projects/{project_id}/triggers', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/triggers', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'ListBuilds' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/projects/{project_id}/builds', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/builds', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'ListWorkerPools' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/workerPools', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ReceiveTriggerWebhook' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/triggers/{trigger}:webhook', - 'body' => 'body', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/triggers/*}:webhook', - 'body' => 'body', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - 'trigger' => [ - 'getters' => [ - 'getTrigger', - ], - ], - ], - ], - 'RetryBuild' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/builds/{id}:retry', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/builds/*}:retry', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'id' => [ - 'getters' => [ - 'getId', - ], - ], - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - ], - ], - 'RunBuildTrigger' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/projects/{project_id}/triggers/{trigger_id}:run', - 'body' => 'source', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/triggers/*}:run', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - 'trigger_id' => [ - 'getters' => [ - 'getTriggerId', - ], - ], - ], - ], - 'UpdateBuildTrigger' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/projects/{project_id}/triggers/{trigger_id}', - 'body' => 'trigger', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{trigger.resource_name=projects/*/locations/*/triggers/*}', - 'body' => 'trigger', - ], - ], - 'placeholders' => [ - 'project_id' => [ - 'getters' => [ - 'getProjectId', - ], - ], - 'trigger.resource_name' => [ - 'getters' => [ - 'getTrigger', - 'getResourceName', - ], - ], - 'trigger_id' => [ - 'getters' => [ - 'getTriggerId', - ], - ], - ], - ], - 'UpdateWorkerPool' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{worker_pool.name=projects/*/locations/*/workerPools/*}', - 'body' => 'worker_pool', - 'placeholders' => [ - 'worker_pool.name' => [ - 'getters' => [ - 'getWorkerPool', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=operations/**}:cancel', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=operations/**}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/Build/v1/tests/Unit/V1/CloudBuildClientTest.php b/owl-bot-staging/Build/v1/tests/Unit/V1/CloudBuildClientTest.php deleted file mode 100644 index 2dcc989cf503..000000000000 --- a/owl-bot-staging/Build/v1/tests/Unit/V1/CloudBuildClientTest.php +++ /dev/null @@ -1,1768 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return CloudBuildClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new CloudBuildClient($options); - } - - /** @test */ - public function approveBuildTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/approveBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $projectId = 'projectId-1969970175'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setProjectId($projectId); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/approveBuildTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $name = 'name3373707'; - $response = $gapicClient->approveBuild($name); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/ApproveBuild', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/approveBuildTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function approveBuildExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/approveBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - $response = $gapicClient->approveBuild($name); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/approveBuildTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function cancelBuildTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id2 = 'id23227150'; - $projectId2 = 'projectId2939242356'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id2); - $expectedResponse->setProjectId($projectId2); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - $response = $gapicClient->cancelBuild($projectId, $id); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/CancelBuild', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getId(); - $this->assertProtobufEquals($id, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function cancelBuildExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - try { - $gapicClient->cancelBuild($projectId, $id); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createBuildTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $id = 'id3355'; - $projectId2 = 'projectId2939242356'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name); - $expectedResponse->setId($id); - $expectedResponse->setProjectId($projectId2); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createBuildTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $projectId = 'projectId-1969970175'; - $build = new Build(); - $response = $gapicClient->createBuild($projectId, $build); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/CreateBuild', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualApiRequestObject->getBuild(); - $this->assertProtobufEquals($build, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createBuildTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createBuildExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $build = new Build(); - $response = $gapicClient->createBuild($projectId, $build); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createBuildTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createBuildTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $resourceName = 'resourceName979421212'; - $id = 'id3355'; - $description = 'description-1724546052'; - $name = 'name3373707'; - $autodetect = true; - $disabled = true; - $filter = 'filter-1274492040'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new BuildTrigger(); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setId($id); - $expectedResponse->setDescription($description); - $expectedResponse->setName($name); - $expectedResponse->setAutodetect($autodetect); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setFilter($filter); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $trigger = new BuildTrigger(); - $response = $gapicClient->createBuildTrigger($projectId, $trigger); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/CreateBuildTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getTrigger(); - $this->assertProtobufEquals($trigger, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createBuildTriggerExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $trigger = new BuildTrigger(); - try { - $gapicClient->createBuildTrigger($projectId, $trigger); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createWorkerPoolTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new WorkerPool(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createWorkerPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $workerPool = new WorkerPool(); - $workerPoolId = 'workerPoolId-300928931'; - $response = $gapicClient->createWorkerPool($formattedParent, $workerPool, $workerPoolId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/CreateWorkerPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getWorkerPool(); - $this->assertProtobufEquals($workerPool, $actualValue); - $actualValue = $actualApiRequestObject->getWorkerPoolId(); - $this->assertProtobufEquals($workerPoolId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createWorkerPoolTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createWorkerPoolExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $workerPool = new WorkerPool(); - $workerPoolId = 'workerPoolId-300928931'; - $response = $gapicClient->createWorkerPool($formattedParent, $workerPool, $workerPoolId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createWorkerPoolTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteBuildTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $gapicClient->deleteBuildTrigger($projectId, $triggerId); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/DeleteBuildTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getTriggerId(); - $this->assertProtobufEquals($triggerId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBuildTriggerExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - try { - $gapicClient->deleteBuildTrigger($projectId, $triggerId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteWorkerPoolTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteWorkerPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - $response = $gapicClient->deleteWorkerPool($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/DeleteWorkerPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteWorkerPoolTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteWorkerPoolExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - $response = $gapicClient->deleteWorkerPool($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteWorkerPoolTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getBuildTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $id2 = 'id23227150'; - $projectId2 = 'projectId2939242356'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id2); - $expectedResponse->setProjectId($projectId2); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - $response = $gapicClient->getBuild($projectId, $id); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/GetBuild', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getId(); - $this->assertProtobufEquals($id, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBuildExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - try { - $gapicClient->getBuild($projectId, $id); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBuildTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $resourceName = 'resourceName979421212'; - $id = 'id3355'; - $description = 'description-1724546052'; - $name2 = 'name2-1052831874'; - $autodetect = true; - $disabled = true; - $filter = 'filter-1274492040'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new BuildTrigger(); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setId($id); - $expectedResponse->setDescription($description); - $expectedResponse->setName($name2); - $expectedResponse->setAutodetect($autodetect); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setFilter($filter); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $response = $gapicClient->getBuildTrigger($projectId, $triggerId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/GetBuildTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getTriggerId(); - $this->assertProtobufEquals($triggerId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBuildTriggerExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - try { - $gapicClient->getBuildTrigger($projectId, $triggerId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getWorkerPoolTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new WorkerPool(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - $response = $gapicClient->getWorkerPool($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/GetWorkerPool', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getWorkerPoolExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->workerPoolName('[PROJECT]', '[LOCATION]', '[WORKER_POOL]'); - try { - $gapicClient->getWorkerPool($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBuildTriggersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $triggersElement = new BuildTrigger(); - $triggers = [ - $triggersElement, - ]; - $expectedResponse = new ListBuildTriggersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTriggers($triggers); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $response = $gapicClient->listBuildTriggers($projectId); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getTriggers()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/ListBuildTriggers', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBuildTriggersExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - try { - $gapicClient->listBuildTriggers($projectId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBuildsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $buildsElement = new Build(); - $builds = [ - $buildsElement, - ]; - $expectedResponse = new ListBuildsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setBuilds($builds); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $response = $gapicClient->listBuilds($projectId); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getBuilds()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/ListBuilds', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBuildsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - try { - $gapicClient->listBuilds($projectId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listWorkerPoolsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $workerPoolsElement = new WorkerPool(); - $workerPools = [ - $workerPoolsElement, - ]; - $expectedResponse = new ListWorkerPoolsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setWorkerPools($workerPools); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listWorkerPools($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getWorkerPools()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/ListWorkerPools', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listWorkerPoolsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listWorkerPools($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function receiveTriggerWebhookTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ReceiveTriggerWebhookResponse(); - $transport->addResponse($expectedResponse); - $response = $gapicClient->receiveTriggerWebhook(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/ReceiveTriggerWebhook', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function receiveTriggerWebhookExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->receiveTriggerWebhook(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function retryBuildTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/retryBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $id2 = 'id23227150'; - $projectId2 = 'projectId2939242356'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id2); - $expectedResponse->setProjectId($projectId2); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/retryBuildTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - $response = $gapicClient->retryBuild($projectId, $id); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/RetryBuild', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualApiRequestObject->getId(); - $this->assertProtobufEquals($id, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/retryBuildTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function retryBuildExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/retryBuildTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $id = 'id3355'; - $response = $gapicClient->retryBuild($projectId, $id); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/retryBuildTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function runBuildTriggerTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runBuildTriggerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $id = 'id3355'; - $projectId2 = 'projectId2939242356'; - $statusDetail = 'statusDetail2089931070'; - $logsBucket = 'logsBucket1565363834'; - $buildTriggerId = 'buildTriggerId1105559411'; - $logUrl = 'logUrl342054388'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new Build(); - $expectedResponse->setName($name2); - $expectedResponse->setId($id); - $expectedResponse->setProjectId($projectId2); - $expectedResponse->setStatusDetail($statusDetail); - $expectedResponse->setLogsBucket($logsBucket); - $expectedResponse->setBuildTriggerId($buildTriggerId); - $expectedResponse->setLogUrl($logUrl); - $expectedResponse->setServiceAccount($serviceAccount); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/runBuildTriggerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $response = $gapicClient->runBuildTrigger($projectId, $triggerId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/RunBuildTrigger', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualApiRequestObject->getTriggerId(); - $this->assertProtobufEquals($triggerId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runBuildTriggerTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function runBuildTriggerExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runBuildTriggerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $response = $gapicClient->runBuildTrigger($projectId, $triggerId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runBuildTriggerTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateBuildTriggerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $resourceName = 'resourceName979421212'; - $id = 'id3355'; - $description = 'description-1724546052'; - $name = 'name3373707'; - $autodetect = true; - $disabled = true; - $filter = 'filter-1274492040'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new BuildTrigger(); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setId($id); - $expectedResponse->setDescription($description); - $expectedResponse->setName($name); - $expectedResponse->setAutodetect($autodetect); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setFilter($filter); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $trigger = new BuildTrigger(); - $response = $gapicClient->updateBuildTrigger($projectId, $triggerId, $trigger); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/UpdateBuildTrigger', $actualFuncCall); - $actualValue = $actualRequestObject->getProjectId(); - $this->assertProtobufEquals($projectId, $actualValue); - $actualValue = $actualRequestObject->getTriggerId(); - $this->assertProtobufEquals($triggerId, $actualValue); - $actualValue = $actualRequestObject->getTrigger(); - $this->assertProtobufEquals($trigger, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBuildTriggerExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $projectId = 'projectId-1969970175'; - $triggerId = 'triggerId1363517698'; - $trigger = new BuildTrigger(); - try { - $gapicClient->updateBuildTrigger($projectId, $triggerId, $trigger); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateWorkerPoolTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new WorkerPool(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateWorkerPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $workerPool = new WorkerPool(); - $response = $gapicClient->updateWorkerPool($workerPool); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v1.CloudBuild/UpdateWorkerPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getWorkerPool(); - $this->assertProtobufEquals($workerPool, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateWorkerPoolTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateWorkerPoolExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateWorkerPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $workerPool = new WorkerPool(); - $response = $gapicClient->updateWorkerPool($workerPool); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateWorkerPoolTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Cloudbuild.php b/owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Cloudbuild.php deleted file mode 100644 index 70eca5b4b2d7..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Cloudbuild.php +++ /dev/null @@ -1,53 +0,0 @@ -internalAddGeneratedFile( - ' -‹ -.google/devtools/cloudbuild/v2/cloudbuild.protogoogle.devtools.cloudbuild.v2google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.protogoogle/protobuf/timestamp.proto"€ -OperationMetadata4 - create_time ( 2.google.protobuf.TimestampBàA1 -end_time ( 2.google.protobuf.TimestampBàA -target ( BàA -verb ( BàA -status_message ( BàA# -requested_cancellation (BàA - api_version ( BàA"’ -"RunWorkflowCustomOperationMetadata4 - create_time ( 2.google.protobuf.TimestampBàA1 -end_time ( 2.google.protobuf.TimestampBàA -verb ( BàA# -requested_cancellation (BàA - api_version ( BàA -target ( BàA -pipeline_run_id ( BàAB£ -com.google.cloudbuild.v2BCloudBuildProtoPZ>cloud.google.com/go/cloudbuild/apiv2/cloudbuildpb;cloudbuildpb¢GCBªGoogle.Cloud.CloudBuild.V2ÊGoogle\\Cloud\\Build\\V2êGoogle::Cloud::Build::V2êAN -compute.googleapis.com/Network,projects/{project}/global/networks/{network}êAY -!iam.googleapis.com/ServiceAccount4projects/{project}/serviceAccounts/{service_account}êAJ -#secretmanager.googleapis.com/Secret#projects/{project}/secrets/{secret}êAd -*secretmanager.googleapis.com/SecretVersion6projects/{project}/secrets/{secret}/versions/{version}êA| -0cloudbuild.googleapis.com/githubEnterpriseConfigHprojects/{project}/locations/{location}/githubEnterpriseConfigs/{config}bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Repositories.php b/owl-bot-staging/Build/v2/proto/src/GPBMetadata/Google/Devtools/Cloudbuild/V2/Repositories.php deleted file mode 100644 index a0d2840db63904ef45f11a5be0826dab7ff698f5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9721 zcmb_iOKcoj6`k&m6Z<)i?U#w&=_pK1O+*so>7MBfzse+W+3wgL*|B3gi4wJ@Ro(sE zE>fmvqK!IX6@O!L7coK zEv`#<*0-h7;>z}$K6zXK(vn<0c)C{XxuQqj~Uf3@d9AaCp?pcmb z+&p8Bkg4qv*Vbx8TH2UjBc4{*JgvOM_>>m~pYlS$r+mM79if_`xvsPs;fJ0f3I5s5 zs-f2;*V8=s?~?9TbW`_q&Cs8MUN@v2&2R}Y=pMV%G;5x2nGz*fH*4g|Rf+SYV=vjD z577IPZBWyIS;{M>M;uc#KvuWr=r(A#0Yep~LA=1A^v#v4Vp_^h-;u6x85N~V$QzR9 zG)Z)JNpgtSbj<5aZpxq)Je7OcO||v1YMK_cf@Qjj66zGP=tsC<=*08}qq(gUqdre| zwSC=k1|wbeJiBVu4+f*!BqHPztF~&H4X0_Ey4fhN+ceMzGfm)euy<+C_686*AZ2D+ z)7;0&l?`aObx0IX+p~MqvH*SirY^!!t=EI-yA3&eC5RUqJ(tlR7SKC`CM&+kDe``L z=fm{Q?-z5^f}v*XkoYu+c#`Mdh%u96$zlTO^4gp-PP}*z;zKj-gc`g^{0zi@v{7b1al&Wb177D5p$*305SVQ-A zo7GCqGI#Vwc8Jk^#hWt3W6kinlXJRhUrR#aEsD$OHH8Ry6$RKgVeKQz-Sm}(Wpbf05#o! zY|oydFZtMYG^&NTm>rig;0q;YUJzcmHy;62P|i8Pr_l+hS&i%j%rTNHqKU2%qbT#3 z9Pog^V`yk!GnyoursI|LH&V*?QlG1zq|l{EF7eQSG;;G$atq=7cn;$5TM%k);hA`9 z6%4D!v8?dSe{2;%dm%Fn4S%#|M#CR&5rscCQ>pp0Xfk{u94>!1jV8M+k3T>|;JOA6 z^fSe;#h9>*K^`2~5Dt7DodRfcDK};o?y6~oG?r79rlYg0VfmDin`np;<8x?oYg=6^ zRqox{+9)lo++HayPP~Sv5Z)-=SzNiZR9V<8soSNBy0I~lioUpH{DTydZWFJzyQ-UyX|zSVk4^GX6VMsYL2D9N zUVy;tOEvw4`sIWkou92Z)LEQREe`N9|K zESlk;_B0b*=Lltk{M}-7_c@)1(OCkFe`1Y~c2yn~b2Po?jXJ4<8 zN?iwRgf8{KM|1=uMvHNXzQxHGed+~PET|D(*QnIA>?jo*Ja>jp1VP}NiK4H_+(&4t z51To3O2{XYrofWsDk@(V?*p;Bt;_V1|B*o`61qJKF(8UV_AKxwMU(()(w!ALVXf_` z(7e*d*7c4GbTUx|3iaw=flg67zfuMI8C0MjA6kLJ`SGKpR-m?3VBwkLui*|_Gi_*9 z1ZRom;sF#VK)mrzn1KAWDC|@iGWzM{2ObB2f%6kEqzN&{y0{=l0CiGm8W0Mw03u(M zRv-1>M<;E~0mN%Ze4MPN&$rbKI%PaYhceJ&nZ`LZ7S^2#Kqc)mInK$O==CMyg%rNj zN?WTsP?Z8_Os(o}gsJOuJ(?{NRzC+#cTF#9-c9JX0|&VYOI~Q4{w41>5CHdBM;?y$ zm2P(-4ZOi!SO^+^y8K}9)N7d#EFq!TjX`m=o>ca9*QI?f_4#nnk+Sjxg?f6C7^GL! z9>M>?BrHLwB+%9BY_(#U#sQZkk}@HF_!jFECJCD)uy+U!!c@uInjmFD9vvz3s}%au zyav4<&-g%m*ta?!1=i58!&^od#HU?ZTnF7D$$^lA=^|Ir8-2w+re09MNMH(I06cIQ zg)HPBLQc^{4qn9@_%Kin*c`w*JV_f(+m{{PfHf}f=420LyX8413-*VWAW1_7{4hI$ zb(1COhbYGu5}QP;KX7!9Y|~YSKRv8xoS+J~SGU7bHPl0Xh|UH4kC}D3jHWty3tz!H zo3EBw6M(Owaq_XP^F2Sl4a4i~A?=#1p$h@`sAZ0CisH-jXfm|b8ecx(AEnVmXRCpe z;X_wx%3buAUXfk0e6as1|2*}bzy0ge^bNT{H|U@7Hs(gq zFz;e+7}^f@F-zNC%S`Kq%60(ppHpbOqe;PWi>!|EzSMEP?;_(ND$lj4kleQ~RMF4k zPazaLo1WNE>?H8jhzZ4C@K9VXDl8PkP|7DaetT3-g*;}(W-9HijvS2tNui0(t}50l zodgN3@_lZVcV}KP4xg*b=v?PsGdsV)11I560$>V3D^~A5jY}Lb{g&&!D&LF;rj873 zTVX1Z0v6&_Skz|2M<1sm$_;Fy-=)!XpH>Xth(WAAbO{6HkKADE@&`vWST$^XmDJ1& zbzES(BO2D{>SlbqIk4gW!~s5H`vd?Vj`ocd2k;?0bQ1V#d_5*qy6FVuueT|6DC8fOHDLw#1ah83S7^FewK@rWwPGs3XFP=GW{$@t z#|eG^OQEwpx@r@C8?9`J~xcMXI<`3nEEZ3c&MNibCbVjhE)oO75(!K&< zsUN{k{O=Sx6Ntn*dHh~d<)e*%F0Kh`p9Bv2*4Oma^0DBrCV}Ts`0SEb^~vo}SOUN}=%N z$rGVOaL_^bV)>Pyw{1Az-Lag#`M;!577j6eeIuOri}O<2v&Jncprd zm)VyxTrm1Po#metg%K(W`=luFN&R;6GYNb*SV+Yj*V5|4Zb89mZSdSGh_erPDV|!@ llfcrmu3Zl9bIkJFLXpcwaA*dXpL$#@Vk7wlpcZN&^naEDAd~google.devtools.cloudbuild.v2.BatchCreateRepositoriesRequest - */ -class BatchCreateRepositoriesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The request messages specifying the repositories to create. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.CreateRepositoryRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $requests; - - /** - * @param string $parent Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. Please see - * {@see RepositoryManagerClient::connectionName()} for help formatting this field. - * @param \Google\Cloud\Build\V2\CreateRepositoryRequest[] $requests Required. The request messages specifying the repositories to create. - * - * @return \Google\Cloud\Build\V2\BatchCreateRepositoriesRequest - * - * @experimental - */ - public static function build(string $parent, array $requests): self - { - return (new self()) - ->setParent($parent) - ->setRequests($requests); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. - * @type array<\Google\Cloud\Build\V2\CreateRepositoryRequest>|\Google\Protobuf\Internal\RepeatedField $requests - * Required. The request messages specifying the repositories to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The request messages specifying the repositories to create. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.CreateRepositoryRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Required. The request messages specifying the repositories to create. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.CreateRepositoryRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\Build\V2\CreateRepositoryRequest>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V2\CreateRepositoryRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/BatchCreateRepositoriesResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/BatchCreateRepositoriesResponse.php deleted file mode 100644 index 4aec29b05e24..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/BatchCreateRepositoriesResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.devtools.cloudbuild.v2.BatchCreateRepositoriesResponse - */ -class BatchCreateRepositoriesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Repository resources created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - */ - private $repositories; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $repositories - * Repository resources created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Repository resources created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRepositories() - { - return $this->repositories; - } - - /** - * Repository resources created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @param array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRepositories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V2\Repository::class); - $this->repositories = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Connection.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Connection.php deleted file mode 100644 index 2d17c92690c1..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Connection.php +++ /dev/null @@ -1,435 +0,0 @@ -google.devtools.cloudbuild.v2.Connection - */ -class Connection extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The resource name of the connection, in the format - * `projects/{project}/locations/{location}/connections/{connection_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Installation state of the Connection. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState installation_state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $installation_state = null; - /** - * If disabled is set to true, functionality is disabled for this connection. - * Repository based API methods and webhooks processing for repositories in - * this connection will be disabled. - * - * Generated from protobuf field bool disabled = 13; - */ - protected $disabled = false; - /** - * Output only. Set to true when the connection is being set up or updated in - * the background. - * - * Generated from protobuf field bool reconciling = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $reconciling = false; - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 15; - */ - private $annotations; - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 16; - */ - protected $etag = ''; - protected $connection_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. The resource name of the connection, in the format - * `projects/{project}/locations/{location}/connections/{connection_id}`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Server assigned timestamp for when the connection was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Server assigned timestamp for when the connection was updated. - * @type \Google\Cloud\Build\V2\GitHubConfig $github_config - * Configuration for connections to github.com. - * @type \Google\Cloud\Build\V2\GitHubEnterpriseConfig $github_enterprise_config - * Configuration for connections to an instance of GitHub Enterprise. - * @type \Google\Cloud\Build\V2\InstallationState $installation_state - * Output only. Installation state of the Connection. - * @type bool $disabled - * If disabled is set to true, functionality is disabled for this connection. - * Repository based API methods and webhooks processing for repositories in - * this connection will be disabled. - * @type bool $reconciling - * Output only. Set to true when the connection is being set up or updated in - * the background. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Allows clients to store small amounts of arbitrary data. - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The resource name of the connection, in the format - * `projects/{project}/locations/{location}/connections/{connection_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. The resource name of the connection, in the format - * `projects/{project}/locations/{location}/connections/{connection_id}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Configuration for connections to github.com. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.GitHubConfig github_config = 5; - * @return \Google\Cloud\Build\V2\GitHubConfig|null - */ - public function getGithubConfig() - { - return $this->readOneof(5); - } - - public function hasGithubConfig() - { - return $this->hasOneof(5); - } - - /** - * Configuration for connections to github.com. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.GitHubConfig github_config = 5; - * @param \Google\Cloud\Build\V2\GitHubConfig $var - * @return $this - */ - public function setGithubConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\GitHubConfig::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Configuration for connections to an instance of GitHub Enterprise. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.GitHubEnterpriseConfig github_enterprise_config = 6; - * @return \Google\Cloud\Build\V2\GitHubEnterpriseConfig|null - */ - public function getGithubEnterpriseConfig() - { - return $this->readOneof(6); - } - - public function hasGithubEnterpriseConfig() - { - return $this->hasOneof(6); - } - - /** - * Configuration for connections to an instance of GitHub Enterprise. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.GitHubEnterpriseConfig github_enterprise_config = 6; - * @param \Google\Cloud\Build\V2\GitHubEnterpriseConfig $var - * @return $this - */ - public function setGithubEnterpriseConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\GitHubEnterpriseConfig::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Output only. Installation state of the Connection. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState installation_state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Build\V2\InstallationState|null - */ - public function getInstallationState() - { - return $this->installation_state; - } - - public function hasInstallationState() - { - return isset($this->installation_state); - } - - public function clearInstallationState() - { - unset($this->installation_state); - } - - /** - * Output only. Installation state of the Connection. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState installation_state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Build\V2\InstallationState $var - * @return $this - */ - public function setInstallationState($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\InstallationState::class); - $this->installation_state = $var; - - return $this; - } - - /** - * If disabled is set to true, functionality is disabled for this connection. - * Repository based API methods and webhooks processing for repositories in - * this connection will be disabled. - * - * Generated from protobuf field bool disabled = 13; - * @return bool - */ - public function getDisabled() - { - return $this->disabled; - } - - /** - * If disabled is set to true, functionality is disabled for this connection. - * Repository based API methods and webhooks processing for repositories in - * this connection will be disabled. - * - * Generated from protobuf field bool disabled = 13; - * @param bool $var - * @return $this - */ - public function setDisabled($var) - { - GPBUtil::checkBool($var); - $this->disabled = $var; - - return $this; - } - - /** - * Output only. Set to true when the connection is being set up or updated in - * the background. - * - * Generated from protobuf field bool reconciling = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getReconciling() - { - return $this->reconciling; - } - - /** - * Output only. Set to true when the connection is being set up or updated in - * the background. - * - * Generated from protobuf field bool reconciling = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setReconciling($var) - { - GPBUtil::checkBool($var); - $this->reconciling = $var; - - return $this; - } - - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 15; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 15; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 16; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 16; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * @return string - */ - public function getConnectionConfig() - { - return $this->whichOneof("connection_config"); - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateConnectionRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateConnectionRequest.php deleted file mode 100644 index 4ba96b1380b1..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateConnectionRequest.php +++ /dev/null @@ -1,183 +0,0 @@ -google.devtools.cloudbuild.v2.CreateConnectionRequest - */ -class CreateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The Connection to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $connection = null; - /** - * Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $connection_id = ''; - - /** - * @param string $parent Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. Please see - * {@see RepositoryManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Build\V2\Connection $connection Required. The Connection to create. - * @param string $connectionId Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * @return \Google\Cloud\Build\V2\CreateConnectionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Build\V2\Connection $connection, string $connectionId): self - { - return (new self()) - ->setParent($parent) - ->setConnection($connection) - ->setConnectionId($connectionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. - * @type \Google\Cloud\Build\V2\Connection $connection - * Required. The Connection to create. - * @type string $connection_id - * Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The Connection to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V2\Connection|null - */ - public function getConnection() - { - return $this->connection; - } - - public function hasConnection() - { - return isset($this->connection); - } - - public function clearConnection() - { - unset($this->connection); - } - - /** - * Required. The Connection to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V2\Connection $var - * @return $this - */ - public function setConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\Connection::class); - $this->connection = $var; - - return $this; - } - - /** - * Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getConnectionId() - { - return $this->connection_id; - } - - /** - * Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setConnectionId($var) - { - GPBUtil::checkString($var, True); - $this->connection_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateRepositoryRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateRepositoryRequest.php deleted file mode 100644 index 5dbc70bca90c..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/CreateRepositoryRequest.php +++ /dev/null @@ -1,188 +0,0 @@ -google.devtools.cloudbuild.v2.CreateRepositoryRequest - */ -class CreateRepositoryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The repository to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Repository repository = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $repository = null; - /** - * Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string repository_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $repository_id = ''; - - /** - * @param string $parent Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. Please see - * {@see RepositoryManagerClient::connectionName()} for help formatting this field. - * @param \Google\Cloud\Build\V2\Repository $repository Required. The repository to create. - * @param string $repositoryId Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * @return \Google\Cloud\Build\V2\CreateRepositoryRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Build\V2\Repository $repository, string $repositoryId): self - { - return (new self()) - ->setParent($parent) - ->setRepository($repository) - ->setRepositoryId($repositoryId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. - * @type \Google\Cloud\Build\V2\Repository $repository - * Required. The repository to create. - * @type string $repository_id - * Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The repository to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Repository repository = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V2\Repository|null - */ - public function getRepository() - { - return $this->repository; - } - - public function hasRepository() - { - return isset($this->repository); - } - - public function clearRepository() - { - unset($this->repository); - } - - /** - * Required. The repository to create. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Repository repository = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V2\Repository $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\Repository::class); - $this->repository = $var; - - return $this; - } - - /** - * Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string repository_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getRepositoryId() - { - return $this->repository_id; - } - - /** - * Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * - * Generated from protobuf field string repository_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setRepositoryId($var) - { - GPBUtil::checkString($var, True); - $this->repository_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteConnectionRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteConnectionRequest.php deleted file mode 100644 index d76949b9bafc..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteConnectionRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.devtools.cloudbuild.v2.DeleteConnectionRequest - */ -class DeleteConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - */ - protected $etag = ''; - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - */ - protected $validate_only = false; - - /** - * @param string $name Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. Please see - * {@see RepositoryManagerClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\DeleteConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. - * @type string $etag - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, deletion will be blocked and an ABORTED error will be returned. - * @type bool $validate_only - * If set, validate the request, but do not actually post it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteRepositoryRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteRepositoryRequest.php deleted file mode 100644 index c12878d13cb8..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/DeleteRepositoryRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.devtools.cloudbuild.v2.DeleteRepositoryRequest - */ -class DeleteRepositoryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * The current etag of the repository. - * If an etag is provided and does not match the current etag of the - * repository, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - */ - protected $etag = ''; - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - */ - protected $validate_only = false; - - /** - * @param string $name Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. Please see - * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\DeleteRepositoryRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * @type string $etag - * The current etag of the repository. - * If an etag is provided and does not match the current etag of the - * repository, deletion will be blocked and an ABORTED error will be returned. - * @type bool $validate_only - * If set, validate the request, but do not actually post it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The current etag of the repository. - * If an etag is provided and does not match the current etag of the - * repository, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * The current etag of the repository. - * If an etag is provided and does not match the current etag of the - * repository, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request, but do not actually post it. - * - * Generated from protobuf field bool validate_only = 3; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesRequest.php deleted file mode 100644 index 677401c74cc3..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesRequest.php +++ /dev/null @@ -1,139 +0,0 @@ -google.devtools.cloudbuild.v2.FetchLinkableRepositoriesRequest - */ -class FetchLinkableRepositoriesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Connection. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string connection = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $connection = ''; - /** - * Number of results to return in the list. Default to 20. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $connection - * Required. The name of the Connection. - * Format: `projects/*/locations/*/connections/*`. - * @type int $page_size - * Number of results to return in the list. Default to 20. - * @type string $page_token - * Page start. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Connection. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string connection = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getConnection() - { - return $this->connection; - } - - /** - * Required. The name of the Connection. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string connection = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setConnection($var) - { - GPBUtil::checkString($var, True); - $this->connection = $var; - - return $this; - } - - /** - * Number of results to return in the list. Default to 20. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results to return in the list. Default to 20. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesResponse.php deleted file mode 100644 index cab0cfef5019..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchLinkableRepositoriesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.devtools.cloudbuild.v2.FetchLinkableRepositoriesResponse - */ -class FetchLinkableRepositoriesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * repositories ready to be created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - */ - private $repositories; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $repositories - * repositories ready to be created. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * repositories ready to be created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRepositories() - { - return $this->repositories; - } - - /** - * repositories ready to be created. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @param array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRepositories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V2\Repository::class); - $this->repositories = $arr; - - return $this; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenRequest.php deleted file mode 100644 index ab9057b88e0a..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.devtools.cloudbuild.v2.FetchReadTokenRequest - */ -class FetchReadTokenRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $repository = ''; - - /** - * @param string $repository Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. Please see - * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\FetchReadTokenRequest - * - * @experimental - */ - public static function build(string $repository): self - { - return (new self()) - ->setRepository($repository); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $repository - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getRepository() - { - return $this->repository; - } - - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkString($var, True); - $this->repository = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenResponse.php deleted file mode 100644 index 3302adc79daf..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadTokenResponse.php +++ /dev/null @@ -1,111 +0,0 @@ -google.devtools.cloudbuild.v2.FetchReadTokenResponse - */ -class FetchReadTokenResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The token content. - * - * Generated from protobuf field string token = 1; - */ - protected $token = ''; - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - */ - protected $expiration_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $token - * The token content. - * @type \Google\Protobuf\Timestamp $expiration_time - * Expiration timestamp. Can be empty if unknown or non-expiring. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * The token content. - * - * Generated from protobuf field string token = 1; - * @return string - */ - public function getToken() - { - return $this->token; - } - - /** - * The token content. - * - * Generated from protobuf field string token = 1; - * @param string $var - * @return $this - */ - public function setToken($var) - { - GPBUtil::checkString($var, True); - $this->token = $var; - - return $this; - } - - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExpirationTime() - { - return $this->expiration_time; - } - - public function hasExpirationTime() - { - return isset($this->expiration_time); - } - - public function clearExpirationTime() - { - unset($this->expiration_time); - } - - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpirationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expiration_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenRequest.php deleted file mode 100644 index 5c24c1711c42..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.devtools.cloudbuild.v2.FetchReadWriteTokenRequest - */ -class FetchReadWriteTokenRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $repository = ''; - - /** - * @param string $repository Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. Please see - * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\FetchReadWriteTokenRequest - * - * @experimental - */ - public static function build(string $repository): self - { - return (new self()) - ->setRepository($repository); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $repository - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getRepository() - { - return $this->repository; - } - - /** - * Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string repository = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRepository($var) - { - GPBUtil::checkString($var, True); - $this->repository = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenResponse.php deleted file mode 100644 index c38b59dc84b1..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/FetchReadWriteTokenResponse.php +++ /dev/null @@ -1,111 +0,0 @@ -google.devtools.cloudbuild.v2.FetchReadWriteTokenResponse - */ -class FetchReadWriteTokenResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The token content. - * - * Generated from protobuf field string token = 1; - */ - protected $token = ''; - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - */ - protected $expiration_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $token - * The token content. - * @type \Google\Protobuf\Timestamp $expiration_time - * Expiration timestamp. Can be empty if unknown or non-expiring. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * The token content. - * - * Generated from protobuf field string token = 1; - * @return string - */ - public function getToken() - { - return $this->token; - } - - /** - * The token content. - * - * Generated from protobuf field string token = 1; - * @param string $var - * @return $this - */ - public function setToken($var) - { - GPBUtil::checkString($var, True); - $this->token = $var; - - return $this; - } - - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExpirationTime() - { - return $this->expiration_time; - } - - public function hasExpirationTime() - { - return isset($this->expiration_time); - } - - public function clearExpirationTime() - { - unset($this->expiration_time); - } - - /** - * Expiration timestamp. Can be empty if unknown or non-expiring. - * - * Generated from protobuf field .google.protobuf.Timestamp expiration_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpirationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expiration_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetConnectionRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetConnectionRequest.php deleted file mode 100644 index a5fb8449f96a..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetConnectionRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.devtools.cloudbuild.v2.GetConnectionRequest - */ -class GetConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. Please see - * {@see RepositoryManagerClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\GetConnectionRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetRepositoryRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetRepositoryRequest.php deleted file mode 100644 index 2b71cd243f1f..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GetRepositoryRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.devtools.cloudbuild.v2.GetRepositoryRequest - */ -class GetRepositoryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. Please see - * {@see RepositoryManagerClient::repositoryName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\GetRepositoryRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubConfig.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubConfig.php deleted file mode 100644 index d1435a9df8ea..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubConfig.php +++ /dev/null @@ -1,119 +0,0 @@ -google.devtools.cloudbuild.v2.GitHubConfig - */ -class GitHubConfig extends \Google\Protobuf\Internal\Message -{ - /** - * OAuth credential of the account that authorized the Cloud Build GitHub App. - * It is recommended to use a robot account instead of a human user account. - * The OAuth token must be tied to the Cloud Build GitHub App. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.OAuthCredential authorizer_credential = 1; - */ - protected $authorizer_credential = null; - /** - * GitHub App installation id. - * - * Generated from protobuf field int64 app_installation_id = 2; - */ - protected $app_installation_id = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V2\OAuthCredential $authorizer_credential - * OAuth credential of the account that authorized the Cloud Build GitHub App. - * It is recommended to use a robot account instead of a human user account. - * The OAuth token must be tied to the Cloud Build GitHub App. - * @type int|string $app_installation_id - * GitHub App installation id. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * OAuth credential of the account that authorized the Cloud Build GitHub App. - * It is recommended to use a robot account instead of a human user account. - * The OAuth token must be tied to the Cloud Build GitHub App. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.OAuthCredential authorizer_credential = 1; - * @return \Google\Cloud\Build\V2\OAuthCredential|null - */ - public function getAuthorizerCredential() - { - return $this->authorizer_credential; - } - - public function hasAuthorizerCredential() - { - return isset($this->authorizer_credential); - } - - public function clearAuthorizerCredential() - { - unset($this->authorizer_credential); - } - - /** - * OAuth credential of the account that authorized the Cloud Build GitHub App. - * It is recommended to use a robot account instead of a human user account. - * The OAuth token must be tied to the Cloud Build GitHub App. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.OAuthCredential authorizer_credential = 1; - * @param \Google\Cloud\Build\V2\OAuthCredential $var - * @return $this - */ - public function setAuthorizerCredential($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\OAuthCredential::class); - $this->authorizer_credential = $var; - - return $this; - } - - /** - * GitHub App installation id. - * - * Generated from protobuf field int64 app_installation_id = 2; - * @return int|string - */ - public function getAppInstallationId() - { - return $this->app_installation_id; - } - - /** - * GitHub App installation id. - * - * Generated from protobuf field int64 app_installation_id = 2; - * @param int|string $var - * @return $this - */ - public function setAppInstallationId($var) - { - GPBUtil::checkInt64($var); - $this->app_installation_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubEnterpriseConfig.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubEnterpriseConfig.php deleted file mode 100644 index 333e58603534..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/GitHubEnterpriseConfig.php +++ /dev/null @@ -1,407 +0,0 @@ -google.devtools.cloudbuild.v2.GitHubEnterpriseConfig - */ -class GitHubEnterpriseConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The URI of the GitHub Enterprise host this connection is for. - * - * Generated from protobuf field string host_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $host_uri = ''; - /** - * Required. API Key used for authentication of webhook events. - * - * Generated from protobuf field string api_key = 12 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $api_key = ''; - /** - * Id of the GitHub App created from the manifest. - * - * Generated from protobuf field int64 app_id = 2; - */ - protected $app_id = 0; - /** - * The URL-friendly name of the GitHub App. - * - * Generated from protobuf field string app_slug = 13; - */ - protected $app_slug = ''; - /** - * SecretManager resource containing the private key of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string private_key_secret_version = 4 [(.google.api.resource_reference) = { - */ - protected $private_key_secret_version = ''; - /** - * SecretManager resource containing the webhook secret of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string webhook_secret_secret_version = 5 [(.google.api.resource_reference) = { - */ - protected $webhook_secret_secret_version = ''; - /** - * ID of the installation of the GitHub App. - * - * Generated from protobuf field int64 app_installation_id = 9; - */ - protected $app_installation_id = 0; - /** - * Configuration for using Service Directory to privately connect to a GitHub - * Enterprise server. This should only be set if the GitHub Enterprise server - * is hosted on-premises and not reachable by public internet. If this field - * is left empty, calls to the GitHub Enterprise server will be made over the - * public internet. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.ServiceDirectoryConfig service_directory_config = 10; - */ - protected $service_directory_config = null; - /** - * SSL certificate to use for requests to GitHub Enterprise. - * - * Generated from protobuf field string ssl_ca = 11; - */ - protected $ssl_ca = ''; - /** - * Output only. GitHub Enterprise version installed at the host_uri. - * - * Generated from protobuf field string server_version = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $server_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $host_uri - * Required. The URI of the GitHub Enterprise host this connection is for. - * @type string $api_key - * Required. API Key used for authentication of webhook events. - * @type int|string $app_id - * Id of the GitHub App created from the manifest. - * @type string $app_slug - * The URL-friendly name of the GitHub App. - * @type string $private_key_secret_version - * SecretManager resource containing the private key of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * @type string $webhook_secret_secret_version - * SecretManager resource containing the webhook secret of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * @type int|string $app_installation_id - * ID of the installation of the GitHub App. - * @type \Google\Cloud\Build\V2\ServiceDirectoryConfig $service_directory_config - * Configuration for using Service Directory to privately connect to a GitHub - * Enterprise server. This should only be set if the GitHub Enterprise server - * is hosted on-premises and not reachable by public internet. If this field - * is left empty, calls to the GitHub Enterprise server will be made over the - * public internet. - * @type string $ssl_ca - * SSL certificate to use for requests to GitHub Enterprise. - * @type string $server_version - * Output only. GitHub Enterprise version installed at the host_uri. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The URI of the GitHub Enterprise host this connection is for. - * - * Generated from protobuf field string host_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getHostUri() - { - return $this->host_uri; - } - - /** - * Required. The URI of the GitHub Enterprise host this connection is for. - * - * Generated from protobuf field string host_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setHostUri($var) - { - GPBUtil::checkString($var, True); - $this->host_uri = $var; - - return $this; - } - - /** - * Required. API Key used for authentication of webhook events. - * - * Generated from protobuf field string api_key = 12 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getApiKey() - { - return $this->api_key; - } - - /** - * Required. API Key used for authentication of webhook events. - * - * Generated from protobuf field string api_key = 12 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setApiKey($var) - { - GPBUtil::checkString($var, True); - $this->api_key = $var; - - return $this; - } - - /** - * Id of the GitHub App created from the manifest. - * - * Generated from protobuf field int64 app_id = 2; - * @return int|string - */ - public function getAppId() - { - return $this->app_id; - } - - /** - * Id of the GitHub App created from the manifest. - * - * Generated from protobuf field int64 app_id = 2; - * @param int|string $var - * @return $this - */ - public function setAppId($var) - { - GPBUtil::checkInt64($var); - $this->app_id = $var; - - return $this; - } - - /** - * The URL-friendly name of the GitHub App. - * - * Generated from protobuf field string app_slug = 13; - * @return string - */ - public function getAppSlug() - { - return $this->app_slug; - } - - /** - * The URL-friendly name of the GitHub App. - * - * Generated from protobuf field string app_slug = 13; - * @param string $var - * @return $this - */ - public function setAppSlug($var) - { - GPBUtil::checkString($var, True); - $this->app_slug = $var; - - return $this; - } - - /** - * SecretManager resource containing the private key of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string private_key_secret_version = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getPrivateKeySecretVersion() - { - return $this->private_key_secret_version; - } - - /** - * SecretManager resource containing the private key of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string private_key_secret_version = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPrivateKeySecretVersion($var) - { - GPBUtil::checkString($var, True); - $this->private_key_secret_version = $var; - - return $this; - } - - /** - * SecretManager resource containing the webhook secret of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string webhook_secret_secret_version = 5 [(.google.api.resource_reference) = { - * @return string - */ - public function getWebhookSecretSecretVersion() - { - return $this->webhook_secret_secret_version; - } - - /** - * SecretManager resource containing the webhook secret of the GitHub App, - * formatted as `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string webhook_secret_secret_version = 5 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setWebhookSecretSecretVersion($var) - { - GPBUtil::checkString($var, True); - $this->webhook_secret_secret_version = $var; - - return $this; - } - - /** - * ID of the installation of the GitHub App. - * - * Generated from protobuf field int64 app_installation_id = 9; - * @return int|string - */ - public function getAppInstallationId() - { - return $this->app_installation_id; - } - - /** - * ID of the installation of the GitHub App. - * - * Generated from protobuf field int64 app_installation_id = 9; - * @param int|string $var - * @return $this - */ - public function setAppInstallationId($var) - { - GPBUtil::checkInt64($var); - $this->app_installation_id = $var; - - return $this; - } - - /** - * Configuration for using Service Directory to privately connect to a GitHub - * Enterprise server. This should only be set if the GitHub Enterprise server - * is hosted on-premises and not reachable by public internet. If this field - * is left empty, calls to the GitHub Enterprise server will be made over the - * public internet. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.ServiceDirectoryConfig service_directory_config = 10; - * @return \Google\Cloud\Build\V2\ServiceDirectoryConfig|null - */ - public function getServiceDirectoryConfig() - { - return $this->service_directory_config; - } - - public function hasServiceDirectoryConfig() - { - return isset($this->service_directory_config); - } - - public function clearServiceDirectoryConfig() - { - unset($this->service_directory_config); - } - - /** - * Configuration for using Service Directory to privately connect to a GitHub - * Enterprise server. This should only be set if the GitHub Enterprise server - * is hosted on-premises and not reachable by public internet. If this field - * is left empty, calls to the GitHub Enterprise server will be made over the - * public internet. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.ServiceDirectoryConfig service_directory_config = 10; - * @param \Google\Cloud\Build\V2\ServiceDirectoryConfig $var - * @return $this - */ - public function setServiceDirectoryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\ServiceDirectoryConfig::class); - $this->service_directory_config = $var; - - return $this; - } - - /** - * SSL certificate to use for requests to GitHub Enterprise. - * - * Generated from protobuf field string ssl_ca = 11; - * @return string - */ - public function getSslCa() - { - return $this->ssl_ca; - } - - /** - * SSL certificate to use for requests to GitHub Enterprise. - * - * Generated from protobuf field string ssl_ca = 11; - * @param string $var - * @return $this - */ - public function setSslCa($var) - { - GPBUtil::checkString($var, True); - $this->ssl_ca = $var; - - return $this; - } - - /** - * Output only. GitHub Enterprise version installed at the host_uri. - * - * Generated from protobuf field string server_version = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getServerVersion() - { - return $this->server_version; - } - - /** - * Output only. GitHub Enterprise version installed at the host_uri. - * - * Generated from protobuf field string server_version = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setServerVersion($var) - { - GPBUtil::checkString($var, True); - $this->server_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState.php deleted file mode 100644 index b1ae1f2c68e8..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState.php +++ /dev/null @@ -1,145 +0,0 @@ -google.devtools.cloudbuild.v2.InstallationState - */ -class InstallationState extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Current step of the installation process. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState.Stage stage = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $stage = 0; - /** - * Output only. Message of what the user should do next to continue the - * installation. Empty string if the installation is already complete. - * - * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $message = ''; - /** - * Output only. Link to follow for next action. Empty string if the - * installation is already complete. - * - * Generated from protobuf field string action_uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $action_uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $stage - * Output only. Current step of the installation process. - * @type string $message - * Output only. Message of what the user should do next to continue the - * installation. Empty string if the installation is already complete. - * @type string $action_uri - * Output only. Link to follow for next action. Empty string if the - * installation is already complete. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Current step of the installation process. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState.Stage stage = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getStage() - { - return $this->stage; - } - - /** - * Output only. Current step of the installation process. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.InstallationState.Stage stage = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setStage($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Build\V2\InstallationState\Stage::class); - $this->stage = $var; - - return $this; - } - - /** - * Output only. Message of what the user should do next to continue the - * installation. Empty string if the installation is already complete. - * - * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMessage() - { - return $this->message; - } - - /** - * Output only. Message of what the user should do next to continue the - * installation. Empty string if the installation is already complete. - * - * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMessage($var) - { - GPBUtil::checkString($var, True); - $this->message = $var; - - return $this; - } - - /** - * Output only. Link to follow for next action. Empty string if the - * installation is already complete. - * - * Generated from protobuf field string action_uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getActionUri() - { - return $this->action_uri; - } - - /** - * Output only. Link to follow for next action. Empty string if the - * installation is already complete. - * - * Generated from protobuf field string action_uri = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setActionUri($var) - { - GPBUtil::checkString($var, True); - $this->action_uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState/Stage.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState/Stage.php deleted file mode 100644 index 710ce522164f..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState/Stage.php +++ /dev/null @@ -1,79 +0,0 @@ -google.devtools.cloudbuild.v2.InstallationState.Stage - */ -class Stage -{ - /** - * No stage specified. - * - * Generated from protobuf enum STAGE_UNSPECIFIED = 0; - */ - const STAGE_UNSPECIFIED = 0; - /** - * Only for GitHub Enterprise. An App creation has been requested. - * The user needs to confirm the creation in their GitHub enterprise host. - * - * Generated from protobuf enum PENDING_CREATE_APP = 1; - */ - const PENDING_CREATE_APP = 1; - /** - * User needs to authorize the GitHub (or Enterprise) App via OAuth. - * - * Generated from protobuf enum PENDING_USER_OAUTH = 2; - */ - const PENDING_USER_OAUTH = 2; - /** - * User needs to follow the link to install the GitHub (or Enterprise) App. - * - * Generated from protobuf enum PENDING_INSTALL_APP = 3; - */ - const PENDING_INSTALL_APP = 3; - /** - * Installation process has been completed. - * - * Generated from protobuf enum COMPLETE = 10; - */ - const COMPLETE = 10; - - private static $valueToName = [ - self::STAGE_UNSPECIFIED => 'STAGE_UNSPECIFIED', - self::PENDING_CREATE_APP => 'PENDING_CREATE_APP', - self::PENDING_USER_OAUTH => 'PENDING_USER_OAUTH', - self::PENDING_INSTALL_APP => 'PENDING_INSTALL_APP', - self::COMPLETE => 'COMPLETE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Stage::class, \Google\Cloud\Build\V2\InstallationState_Stage::class); - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState_Stage.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState_Stage.php deleted file mode 100644 index 102013270e65..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/InstallationState_Stage.php +++ /dev/null @@ -1,16 +0,0 @@ -google.devtools.cloudbuild.v2.ListConnectionsRequest - */ -class ListConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. Please see - * {@see RepositoryManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\ListConnectionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. - * @type int $page_size - * Number of results to return in the list. - * @type string $page_token - * Page start. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListConnectionsResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListConnectionsResponse.php deleted file mode 100644 index 9d9a916d3a00..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListConnectionsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.devtools.cloudbuild.v2.ListConnectionsResponse - */ -class ListConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Connections. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Connection connections = 1; - */ - private $connections; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections - * The list of Connections. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * The list of Connections. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Connection connections = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnections() - { - return $this->connections; - } - - /** - * The list of Connections. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Connection connections = 1; - * @param array<\Google\Cloud\Build\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V2\Connection::class); - $this->connections = $arr; - - return $this; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesRequest.php deleted file mode 100644 index b348f630d745..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.devtools.cloudbuild.v2.ListRepositoriesRequest - */ -class ListRepositoriesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that filters resources listed in the response. - * Expressions must follow API improvement proposal - * [AIP-160](https://google.aip.dev/160). e.g. - * `remote_uri:"https://github.com*"`. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. Please see - * {@see RepositoryManagerClient::connectionName()} for help formatting this field. - * - * @return \Google\Cloud\Build\V2\ListRepositoriesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. - * @type int $page_size - * Number of results to return in the list. - * @type string $page_token - * Page start. - * @type string $filter - * A filter expression that filters resources listed in the response. - * Expressions must follow API improvement proposal - * [AIP-160](https://google.aip.dev/160). e.g. - * `remote_uri:"https://github.com*"`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results to return in the list. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Page start. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * A filter expression that filters resources listed in the response. - * Expressions must follow API improvement proposal - * [AIP-160](https://google.aip.dev/160). e.g. - * `remote_uri:"https://github.com*"`. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that filters resources listed in the response. - * Expressions must follow API improvement proposal - * [AIP-160](https://google.aip.dev/160). e.g. - * `remote_uri:"https://github.com*"`. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesResponse.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesResponse.php deleted file mode 100644 index 54490f450841..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ListRepositoriesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.devtools.cloudbuild.v2.ListRepositoriesResponse - */ -class ListRepositoriesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Repositories. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - */ - private $repositories; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $repositories - * The list of Repositories. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * The list of Repositories. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRepositories() - { - return $this->repositories; - } - - /** - * The list of Repositories. - * - * Generated from protobuf field repeated .google.devtools.cloudbuild.v2.Repository repositories = 1; - * @param array<\Google\Cloud\Build\V2\Repository>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRepositories($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Build\V2\Repository::class); - $this->repositories = $arr; - - return $this; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OAuthCredential.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OAuthCredential.php deleted file mode 100644 index 02ae959dbbb1..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OAuthCredential.php +++ /dev/null @@ -1,106 +0,0 @@ -google.devtools.cloudbuild.v2.OAuthCredential - */ -class OAuthCredential extends \Google\Protobuf\Internal\Message -{ - /** - * A SecretManager resource containing the OAuth token that authorizes - * the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string oauth_token_secret_version = 1 [(.google.api.resource_reference) = { - */ - protected $oauth_token_secret_version = ''; - /** - * Output only. The username associated to this token. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $username = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $oauth_token_secret_version - * A SecretManager resource containing the OAuth token that authorizes - * the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`. - * @type string $username - * Output only. The username associated to this token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * A SecretManager resource containing the OAuth token that authorizes - * the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string oauth_token_secret_version = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getOauthTokenSecretVersion() - { - return $this->oauth_token_secret_version; - } - - /** - * A SecretManager resource containing the OAuth token that authorizes - * the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`. - * - * Generated from protobuf field string oauth_token_secret_version = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setOauthTokenSecretVersion($var) - { - GPBUtil::checkString($var, True); - $this->oauth_token_secret_version = $var; - - return $this; - } - - /** - * Output only. The username associated to this token. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Output only. The username associated to this token. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OperationMetadata.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OperationMetadata.php deleted file mode 100644 index 42a4e11540ab..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/OperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.devtools.cloudbuild.v2.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $status_message = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type string $status_message - * Output only. Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Output only. Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Repository.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Repository.php deleted file mode 100644 index e60bf1135299..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/Repository.php +++ /dev/null @@ -1,269 +0,0 @@ -google.devtools.cloudbuild.v2.Repository - */ -class Repository extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. Resource name of the repository, in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Required. Git Clone HTTPS URI. - * - * Generated from protobuf field string remote_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $remote_uri = ''; - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 6; - */ - private $annotations; - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 7; - */ - protected $etag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. Resource name of the repository, in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * @type string $remote_uri - * Required. Git Clone HTTPS URI. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Server assigned timestamp for when the connection was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Server assigned timestamp for when the connection was updated. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Allows clients to store small amounts of arbitrary data. - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. Resource name of the repository, in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. Resource name of the repository, in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Git Clone HTTPS URI. - * - * Generated from protobuf field string remote_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getRemoteUri() - { - return $this->remote_uri; - } - - /** - * Required. Git Clone HTTPS URI. - * - * Generated from protobuf field string remote_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setRemoteUri($var) - { - GPBUtil::checkString($var, True); - $this->remote_uri = $var; - - return $this; - } - - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Server assigned timestamp for when the connection was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Server assigned timestamp for when the connection was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 6; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Allows clients to store small amounts of arbitrary data. - * - * Generated from protobuf field map annotations = 6; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAnnotations($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->annotations = $arr; - - return $this; - } - - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 7; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields, and may be sent on update and delete requests to ensure the - * client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 7; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RepositoryManagerGrpcClient.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RepositoryManagerGrpcClient.php deleted file mode 100644 index 7028614e11d4..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RepositoryManagerGrpcClient.php +++ /dev/null @@ -1,231 +0,0 @@ -_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/CreateConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single connection. - * @param \Google\Cloud\Build\V2\GetConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetConnection(\Google\Cloud\Build\V2\GetConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/GetConnection', - $argument, - ['\Google\Cloud\Build\V2\Connection', 'decode'], - $metadata, $options); - } - - /** - * Lists Connections in a given project and location. - * @param \Google\Cloud\Build\V2\ListConnectionsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListConnections(\Google\Cloud\Build\V2\ListConnectionsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/ListConnections', - $argument, - ['\Google\Cloud\Build\V2\ListConnectionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Updates a single connection. - * @param \Google\Cloud\Build\V2\UpdateConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateConnection(\Google\Cloud\Build\V2\UpdateConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/UpdateConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single connection. - * @param \Google\Cloud\Build\V2\DeleteConnectionRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteConnection(\Google\Cloud\Build\V2\DeleteConnectionRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/DeleteConnection', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Creates a Repository. - * @param \Google\Cloud\Build\V2\CreateRepositoryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateRepository(\Google\Cloud\Build\V2\CreateRepositoryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/CreateRepository', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Creates multiple repositories inside a connection. - * @param \Google\Cloud\Build\V2\BatchCreateRepositoriesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function BatchCreateRepositories(\Google\Cloud\Build\V2\BatchCreateRepositoriesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/BatchCreateRepositories', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single repository. - * @param \Google\Cloud\Build\V2\GetRepositoryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetRepository(\Google\Cloud\Build\V2\GetRepositoryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/GetRepository', - $argument, - ['\Google\Cloud\Build\V2\Repository', 'decode'], - $metadata, $options); - } - - /** - * Lists Repositories in a given connection. - * @param \Google\Cloud\Build\V2\ListRepositoriesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListRepositories(\Google\Cloud\Build\V2\ListRepositoriesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/ListRepositories', - $argument, - ['\Google\Cloud\Build\V2\ListRepositoriesResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single repository. - * @param \Google\Cloud\Build\V2\DeleteRepositoryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteRepository(\Google\Cloud\Build\V2\DeleteRepositoryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/DeleteRepository', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Fetches read/write token of a given repository. - * @param \Google\Cloud\Build\V2\FetchReadWriteTokenRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function FetchReadWriteToken(\Google\Cloud\Build\V2\FetchReadWriteTokenRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/FetchReadWriteToken', - $argument, - ['\Google\Cloud\Build\V2\FetchReadWriteTokenResponse', 'decode'], - $metadata, $options); - } - - /** - * Fetches read token of a given repository. - * @param \Google\Cloud\Build\V2\FetchReadTokenRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function FetchReadToken(\Google\Cloud\Build\V2\FetchReadTokenRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/FetchReadToken', - $argument, - ['\Google\Cloud\Build\V2\FetchReadTokenResponse', 'decode'], - $metadata, $options); - } - - /** - * FetchLinkableRepositories get repositories from SCM that are - * accessible and could be added to the connection. - * @param \Google\Cloud\Build\V2\FetchLinkableRepositoriesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function FetchLinkableRepositories(\Google\Cloud\Build\V2\FetchLinkableRepositoriesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.devtools.cloudbuild.v2.RepositoryManager/FetchLinkableRepositories', - $argument, - ['\Google\Cloud\Build\V2\FetchLinkableRepositoriesResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RunWorkflowCustomOperationMetadata.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RunWorkflowCustomOperationMetadata.php deleted file mode 100644 index 607954ea33b7..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/RunWorkflowCustomOperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.devtools.cloudbuild.v2.RunWorkflowCustomOperationMetadata - */ -class RunWorkflowCustomOperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $verb = ''; - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $requested_cancellation = false; - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_version = ''; - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $target = ''; - /** - * Output only. ID of the pipeline run created by RunWorkflow. - * - * Generated from protobuf field string pipeline_run_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pipeline_run_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The time the operation finished running. - * @type string $verb - * Output only. Name of the verb executed by the operation. - * @type bool $requested_cancellation - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * Output only. API version used to start the operation. - * @type string $target - * Output only. Server-defined resource path for the target of the operation. - * @type string $pipeline_run_id - * Output only. ID of the pipeline run created by RunWorkflow. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Cloudbuild::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Output only. Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Output only. Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * Output only. API version used to start the operation. - * - * Generated from protobuf field string api_version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Output only. Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Output only. ID of the pipeline run created by RunWorkflow. - * - * Generated from protobuf field string pipeline_run_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPipelineRunId() - { - return $this->pipeline_run_id; - } - - /** - * Output only. ID of the pipeline run created by RunWorkflow. - * - * Generated from protobuf field string pipeline_run_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPipelineRunId($var) - { - GPBUtil::checkString($var, True); - $this->pipeline_run_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ServiceDirectoryConfig.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ServiceDirectoryConfig.php deleted file mode 100644 index 319cc1be7884..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/ServiceDirectoryConfig.php +++ /dev/null @@ -1,76 +0,0 @@ -google.devtools.cloudbuild.v2.ServiceDirectoryConfig - */ -class ServiceDirectoryConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The Service Directory service name. - * Format: - * projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}. - * - * Generated from protobuf field string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $service = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service - * Required. The Service Directory service name. - * Format: - * projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The Service Directory service name. - * Format: - * projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}. - * - * Generated from protobuf field string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * Required. The Service Directory service name. - * Format: - * projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}. - * - * Generated from protobuf field string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/UpdateConnectionRequest.php b/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/UpdateConnectionRequest.php deleted file mode 100644 index 9249d61cca33..000000000000 --- a/owl-bot-staging/Build/v2/proto/src/Google/Cloud/Build/V2/UpdateConnectionRequest.php +++ /dev/null @@ -1,228 +0,0 @@ -google.devtools.cloudbuild.v2.UpdateConnectionRequest - */ -class UpdateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The Connection to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $connection = null; - /** - * The list of fields to be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true, and the connection is not found a new connection - * will be created. In this situation `update_mask` is ignored. - * The creation will succeed only if the input connection has all the - * necessary information (e.g a github_config with both user_oauth_token and - * installation_id properties). - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, update will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 4; - */ - protected $etag = ''; - - /** - * @param \Google\Cloud\Build\V2\Connection $connection Required. The Connection to update. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * - * @return \Google\Cloud\Build\V2\UpdateConnectionRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Build\V2\Connection $connection, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setConnection($connection) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Build\V2\Connection $connection - * Required. The Connection to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * @type bool $allow_missing - * If set to true, and the connection is not found a new connection - * will be created. In this situation `update_mask` is ignored. - * The creation will succeed only if the input connection has all the - * necessary information (e.g a github_config with both user_oauth_token and - * installation_id properties). - * @type string $etag - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, update will be blocked and an ABORTED error will be returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Devtools\Cloudbuild\V2\Repositories::initOnce(); - parent::__construct($data); - } - - /** - * Required. The Connection to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Build\V2\Connection|null - */ - public function getConnection() - { - return $this->connection; - } - - public function hasConnection() - { - return isset($this->connection); - } - - public function clearConnection() - { - unset($this->connection); - } - - /** - * Required. The Connection to update. - * - * Generated from protobuf field .google.devtools.cloudbuild.v2.Connection connection = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Build\V2\Connection $var - * @return $this - */ - public function setConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Build\V2\Connection::class); - $this->connection = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true, and the connection is not found a new connection - * will be created. In this situation `update_mask` is ignored. - * The creation will succeed only if the input connection has all the - * necessary information (e.g a github_config with both user_oauth_token and - * installation_id properties). - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the connection is not found a new connection - * will be created. In this situation `update_mask` is ignored. - * The creation will succeed only if the input connection has all the - * necessary information (e.g a github_config with both user_oauth_token and - * installation_id properties). - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, update will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 4; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, update will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 4; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/batch_create_repositories.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/batch_create_repositories.php deleted file mode 100644 index bd8eef0debf8..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/batch_create_repositories.php +++ /dev/null @@ -1,125 +0,0 @@ -setRemoteUri($requestsRepositoryRemoteUri); - $createRepositoryRequest = (new CreateRepositoryRequest()) - ->setParent($formattedRequestsParent) - ->setRepository($requestsRepository) - ->setRepositoryId($requestsRepositoryId); - $requests = [$createRepositoryRequest,]; - $request = (new BatchCreateRepositoriesRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->batchCreateRepositories($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var BatchCreateRepositoriesResponse $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 = RepositoryManagerClient::connectionName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]' - ); - $formattedRequestsParent = RepositoryManagerClient::connectionName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]' - ); - $requestsRepositoryRemoteUri = '[REMOTE_URI]'; - $requestsRepositoryId = '[REPOSITORY_ID]'; - - batch_create_repositories_sample( - $formattedParent, - $formattedRequestsParent, - $requestsRepositoryRemoteUri, - $requestsRepositoryId - ); -} -// [END cloudbuild_v2_generated_RepositoryManager_BatchCreateRepositories_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_connection.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_connection.php deleted file mode 100644 index 8b83e8387ccd..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_connection.php +++ /dev/null @@ -1,92 +0,0 @@ -setParent($formattedParent) - ->setConnection($connection) - ->setConnectionId($connectionId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->createConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Connection $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 = RepositoryManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $connectionId = '[CONNECTION_ID]'; - - create_connection_sample($formattedParent, $connectionId); -} -// [END cloudbuild_v2_generated_RepositoryManager_CreateConnection_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_repository.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_repository.php deleted file mode 100644 index 49155728473e..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/create_repository.php +++ /dev/null @@ -1,103 +0,0 @@ -setRemoteUri($repositoryRemoteUri); - $request = (new CreateRepositoryRequest()) - ->setParent($formattedParent) - ->setRepository($repository) - ->setRepositoryId($repositoryId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->createRepository($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Repository $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 = RepositoryManagerClient::connectionName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]' - ); - $repositoryRemoteUri = '[REMOTE_URI]'; - $repositoryId = '[REPOSITORY_ID]'; - - create_repository_sample($formattedParent, $repositoryRemoteUri, $repositoryId); -} -// [END cloudbuild_v2_generated_RepositoryManager_CreateRepository_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_connection.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_connection.php deleted file mode 100644 index d8364f47874d..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_connection.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->deleteConnection($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 = RepositoryManagerClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - - delete_connection_sample($formattedName); -} -// [END cloudbuild_v2_generated_RepositoryManager_DeleteConnection_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_repository.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_repository.php deleted file mode 100644 index 28a2a6ef7286..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/delete_repository.php +++ /dev/null @@ -1,86 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->deleteRepository($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 = RepositoryManagerClient::repositoryName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]', - '[REPOSITORY]' - ); - - delete_repository_sample($formattedName); -} -// [END cloudbuild_v2_generated_RepositoryManager_DeleteRepository_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php deleted file mode 100644 index 6f16c82006c7..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_linkable_repositories.php +++ /dev/null @@ -1,82 +0,0 @@ -setConnection($formattedConnection); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->fetchLinkableRepositories($request); - - /** @var Repository $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 -{ - $formattedConnection = RepositoryManagerClient::connectionName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]' - ); - - fetch_linkable_repositories_sample($formattedConnection); -} -// [END cloudbuild_v2_generated_RepositoryManager_FetchLinkableRepositories_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_token.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_token.php deleted file mode 100644 index 3ff6330d2f0f..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_token.php +++ /dev/null @@ -1,77 +0,0 @@ -setRepository($formattedRepository); - - // Call the API and handle any network failures. - try { - /** @var FetchReadTokenResponse $response */ - $response = $repositoryManagerClient->fetchReadToken($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 -{ - $formattedRepository = RepositoryManagerClient::repositoryName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]', - '[REPOSITORY]' - ); - - fetch_read_token_sample($formattedRepository); -} -// [END cloudbuild_v2_generated_RepositoryManager_FetchReadToken_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_write_token.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_write_token.php deleted file mode 100644 index 9a3772b2a0c1..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/fetch_read_write_token.php +++ /dev/null @@ -1,77 +0,0 @@ -setRepository($formattedRepository); - - // Call the API and handle any network failures. - try { - /** @var FetchReadWriteTokenResponse $response */ - $response = $repositoryManagerClient->fetchReadWriteToken($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 -{ - $formattedRepository = RepositoryManagerClient::repositoryName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]', - '[REPOSITORY]' - ); - - fetch_read_write_token_sample($formattedRepository); -} -// [END cloudbuild_v2_generated_RepositoryManager_FetchReadWriteToken_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_connection.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_connection.php deleted file mode 100644 index 9792ba919cb0..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_connection.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Connection $response */ - $response = $repositoryManagerClient->getConnection($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 = RepositoryManagerClient::connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - - get_connection_sample($formattedName); -} -// [END cloudbuild_v2_generated_RepositoryManager_GetConnection_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_iam_policy.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_iam_policy.php deleted file mode 100644 index a9fbed2d0ef2..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_iam_policy.php +++ /dev/null @@ -1,72 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $repositoryManagerClient->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); -} -// [END cloudbuild_v2_generated_RepositoryManager_GetIamPolicy_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_repository.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_repository.php deleted file mode 100644 index 4020e1517ff2..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/get_repository.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Repository $response */ - $response = $repositoryManagerClient->getRepository($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 = RepositoryManagerClient::repositoryName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]', - '[REPOSITORY]' - ); - - get_repository_sample($formattedName); -} -// [END cloudbuild_v2_generated_RepositoryManager_GetRepository_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_connections.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_connections.php deleted file mode 100644 index f19df83f4226..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_connections.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->listConnections($request); - - /** @var Connection $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 = RepositoryManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_connections_sample($formattedParent); -} -// [END cloudbuild_v2_generated_RepositoryManager_ListConnections_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_repositories.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_repositories.php deleted file mode 100644 index 0b414ecde898..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/list_repositories.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $repositoryManagerClient->listRepositories($request); - - /** @var Repository $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 = RepositoryManagerClient::connectionName( - '[PROJECT]', - '[LOCATION]', - '[CONNECTION]' - ); - - list_repositories_sample($formattedParent); -} -// [END cloudbuild_v2_generated_RepositoryManager_ListRepositories_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/set_iam_policy.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/set_iam_policy.php deleted file mode 100644 index 2937d2590e92..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/set_iam_policy.php +++ /dev/null @@ -1,77 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $repositoryManagerClient->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); -} -// [END cloudbuild_v2_generated_RepositoryManager_SetIamPolicy_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/test_iam_permissions.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/test_iam_permissions.php deleted file mode 100644 index cbad5cee2ce3..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/test_iam_permissions.php +++ /dev/null @@ -1,84 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $repositoryManagerClient->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); -} -// [END cloudbuild_v2_generated_RepositoryManager_TestIamPermissions_sync] diff --git a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/update_connection.php b/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/update_connection.php deleted file mode 100644 index 423557d240e3..000000000000 --- a/owl-bot-staging/Build/v2/samples/V2/RepositoryManagerClient/update_connection.php +++ /dev/null @@ -1,71 +0,0 @@ -setConnection($connection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $repositoryManagerClient->updateConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Connection $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 cloudbuild_v2_generated_RepositoryManager_UpdateConnection_sync] diff --git a/owl-bot-staging/Build/v2/src/V2/Gapic/RepositoryManagerGapicClient.php b/owl-bot-staging/Build/v2/src/V2/Gapic/RepositoryManagerGapicClient.php deleted file mode 100644 index c25c770f1b3e..000000000000 --- a/owl-bot-staging/Build/v2/src/V2/Gapic/RepositoryManagerGapicClient.php +++ /dev/null @@ -1,1458 +0,0 @@ -connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $requests = []; - * $operationResponse = $repositoryManagerClient->batchCreateRepositories($formattedParent, $requests); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->batchCreateRepositories($formattedParent, $requests); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'batchCreateRepositories'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * 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. - */ -class RepositoryManagerGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.devtools.cloudbuild.v2.RepositoryManager'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'cloudbuild.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $connectionNameTemplate; - - private static $locationNameTemplate; - - private static $repositoryNameTemplate; - - private static $secretVersionNameTemplate; - - private static $serviceNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/repository_manager_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/repository_manager_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/repository_manager_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/repository_manager_rest_client_config.php', - ], - ], - ]; - } - - private static function getConnectionNameTemplate() - { - if (self::$connectionNameTemplate == null) { - self::$connectionNameTemplate = new PathTemplate('projects/{project}/locations/{location}/connections/{connection}'); - } - - return self::$connectionNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getRepositoryNameTemplate() - { - if (self::$repositoryNameTemplate == null) { - self::$repositoryNameTemplate = new PathTemplate('projects/{project}/locations/{location}/connections/{connection}/repositories/{repository}'); - } - - return self::$repositoryNameTemplate; - } - - private static function getSecretVersionNameTemplate() - { - if (self::$secretVersionNameTemplate == null) { - self::$secretVersionNameTemplate = new PathTemplate('projects/{project}/secrets/{secret}/versions/{version}'); - } - - return self::$secretVersionNameTemplate; - } - - private static function getServiceNameTemplate() - { - if (self::$serviceNameTemplate == null) { - self::$serviceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}'); - } - - return self::$serviceNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'connection' => self::getConnectionNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'repository' => self::getRepositoryNameTemplate(), - 'secretVersion' => self::getSecretVersionNameTemplate(), - 'service' => self::getServiceNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a connection - * resource. - * - * @param string $project - * @param string $location - * @param string $connection - * - * @return string The formatted connection resource. - */ - public static function connectionName($project, $location, $connection) - { - return self::getConnectionNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'connection' => $connection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a repository - * resource. - * - * @param string $project - * @param string $location - * @param string $connection - * @param string $repository - * - * @return string The formatted repository resource. - */ - public static function repositoryName($project, $location, $connection, $repository) - { - return self::getRepositoryNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'connection' => $connection, - 'repository' => $repository, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * secret_version resource. - * - * @param string $project - * @param string $secret - * @param string $version - * - * @return string The formatted secret_version resource. - */ - public static function secretVersionName($project, $secret, $version) - { - return self::getSecretVersionNameTemplate()->render([ - 'project' => $project, - 'secret' => $secret, - 'version' => $version, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a service - * resource. - * - * @param string $project - * @param string $location - * @param string $namespace - * @param string $service - * - * @return string The formatted service resource. - */ - public static function serviceName($project, $location, $namespace, $service) - { - return self::getServiceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'namespace' => $namespace, - 'service' => $service, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - connection: projects/{project}/locations/{location}/connections/{connection} - * - location: projects/{project}/locations/{location} - * - repository: projects/{project}/locations/{location}/connections/{connection}/repositories/{repository} - * - secretVersion: projects/{project}/secrets/{secret}/versions/{version} - * - service: projects/{project}/locations/{location}/namespaces/{namespace}/services/{service} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'cloudbuild.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates multiple repositories inside a connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedParent = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $requests = []; - * $operationResponse = $repositoryManagerClient->batchCreateRepositories($formattedParent, $requests); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->batchCreateRepositories($formattedParent, $requests); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'batchCreateRepositories'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The connection to contain all the repositories being created. - * Format: projects/*/locations/*/connections/* - * The parent field in the CreateRepositoryRequest messages - * must either be empty or match this field. - * @param CreateRepositoryRequest[] $requests Required. The request messages specifying the repositories to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function batchCreateRepositories($parent, $requests, array $optionalArgs = []) - { - $request = new BatchCreateRepositoriesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setRequests($requests); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('BatchCreateRepositories', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a Connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedParent = $repositoryManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * $connection = new Connection(); - * $connectionId = 'connection_id'; - * $operationResponse = $repositoryManagerClient->createConnection($formattedParent, $connection, $connectionId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->createConnection($formattedParent, $connection, $connectionId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'createConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. Project and location where the connection will be created. - * Format: `projects/*/locations/*`. - * @param Connection $connection Required. The Connection to create. - * @param string $connectionId Required. The ID to use for the Connection, which will become the final - * component of the Connection's resource name. Names must be unique - * per-project per-location. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createConnection($parent, $connection, $connectionId, array $optionalArgs = []) - { - $request = new CreateConnectionRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setConnection($connection); - $request->setConnectionId($connectionId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a Repository. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedParent = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $repository = new Repository(); - * $repositoryId = 'repository_id'; - * $operationResponse = $repositoryManagerClient->createRepository($formattedParent, $repository, $repositoryId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->createRepository($formattedParent, $repository, $repositoryId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'createRepository'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The connection to contain the repository. If the request is part - * of a BatchCreateRepositoriesRequest, this field should be empty or match - * the parent specified there. - * @param Repository $repository Required. The repository to create. - * @param string $repositoryId Required. The ID to use for the repository, which will become the final - * component of the repository's resource name. This ID should be unique in - * the connection. Allows alphanumeric characters and any of - * -._~%!$&'()*+,;=@. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createRepository($parent, $repository, $repositoryId, array $optionalArgs = []) - { - $request = new CreateRepositoryRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setRepository($repository); - $request->setRepositoryId($repositoryId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateRepository', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedName = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $operationResponse = $repositoryManagerClient->deleteConnection($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->deleteConnection($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'deleteConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Connection to delete. - * Format: `projects/*/locations/*/connections/*`. - * @param array $optionalArgs { - * Optional. - * - * @type string $etag - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, deletion will be blocked and an ABORTED error will be returned. - * @type bool $validateOnly - * If set, validate the request, but do not actually post it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteConnection($name, array $optionalArgs = []) - { - $request = new DeleteConnectionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['etag'])) { - $request->setEtag($optionalArgs['etag']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single repository. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedName = $repositoryManagerClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - * $operationResponse = $repositoryManagerClient->deleteRepository($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->deleteRepository($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'deleteRepository'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Repository to delete. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * @param array $optionalArgs { - * Optional. - * - * @type string $etag - * The current etag of the repository. - * If an etag is provided and does not match the current etag of the - * repository, deletion will be blocked and an ABORTED error will be returned. - * @type bool $validateOnly - * If set, validate the request, but do not actually post it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteRepository($name, array $optionalArgs = []) - { - $request = new DeleteRepositoryRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['etag'])) { - $request->setEtag($optionalArgs['etag']); - } - - if (isset($optionalArgs['validateOnly'])) { - $request->setValidateOnly($optionalArgs['validateOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteRepository', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * FetchLinkableRepositories get repositories from SCM that are - * accessible and could be added to the connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedConnection = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * // Iterate over pages of elements - * $pagedResponse = $repositoryManagerClient->fetchLinkableRepositories($formattedConnection); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $repositoryManagerClient->fetchLinkableRepositories($formattedConnection); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $connection Required. The name of the Connection. - * Format: `projects/*/locations/*/connections/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function fetchLinkableRepositories($connection, array $optionalArgs = []) - { - $request = new FetchLinkableRepositoriesRequest(); - $requestParamHeaders = []; - $request->setConnection($connection); - $requestParamHeaders['connection'] = $connection; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('FetchLinkableRepositories', $optionalArgs, FetchLinkableRepositoriesResponse::class, $request); - } - - /** - * Fetches read token of a given repository. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedRepository = $repositoryManagerClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - * $response = $repositoryManagerClient->fetchReadToken($formattedRepository); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $repository Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V2\FetchReadTokenResponse - * - * @throws ApiException if the remote call fails - */ - public function fetchReadToken($repository, array $optionalArgs = []) - { - $request = new FetchReadTokenRequest(); - $requestParamHeaders = []; - $request->setRepository($repository); - $requestParamHeaders['repository'] = $repository; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('FetchReadToken', FetchReadTokenResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Fetches read/write token of a given repository. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedRepository = $repositoryManagerClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - * $response = $repositoryManagerClient->fetchReadWriteToken($formattedRepository); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $repository Required. The resource name of the repository in the format - * `projects/*/locations/*/connections/*/repositories/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V2\FetchReadWriteTokenResponse - * - * @throws ApiException if the remote call fails - */ - public function fetchReadWriteToken($repository, array $optionalArgs = []) - { - $request = new FetchReadWriteTokenRequest(); - $requestParamHeaders = []; - $request->setRepository($repository); - $requestParamHeaders['repository'] = $repository; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('FetchReadWriteToken', FetchReadWriteTokenResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedName = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * $response = $repositoryManagerClient->getConnection($formattedName); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Connection to retrieve. - * Format: `projects/*/locations/*/connections/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V2\Connection - * - * @throws ApiException if the remote call fails - */ - public function getConnection($name, array $optionalArgs = []) - { - $request = new GetConnectionRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetConnection', Connection::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single repository. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedName = $repositoryManagerClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - * $response = $repositoryManagerClient->getRepository($formattedName); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the Repository to retrieve. - * Format: `projects/*/locations/*/connections/*/repositories/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Build\V2\Repository - * - * @throws ApiException if the remote call fails - */ - public function getRepository($name, array $optionalArgs = []) - { - $request = new GetRepositoryRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetRepository', Repository::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists Connections in a given project and location. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedParent = $repositoryManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $repositoryManagerClient->listConnections($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $repositoryManagerClient->listConnections($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of Connections. - * Format: `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listConnections($parent, array $optionalArgs = []) - { - $request = new ListConnectionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListConnections', $optionalArgs, ListConnectionsResponse::class, $request); - } - - /** - * Lists Repositories in a given connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $formattedParent = $repositoryManagerClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - * // Iterate over pages of elements - * $pagedResponse = $repositoryManagerClient->listRepositories($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $repositoryManagerClient->listRepositories($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns this collection of Repositories. - * Format: `projects/*/locations/*/connections/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * A filter expression that filters resources listed in the response. - * Expressions must follow API improvement proposal - * [AIP-160](https://google.aip.dev/160). e.g. - * `remote_uri:"https://github.com*"`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listRepositories($parent, array $optionalArgs = []) - { - $request = new ListRepositoriesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListRepositories', $optionalArgs, ListRepositoriesResponse::class, $request); - } - - /** - * Updates a single connection. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $connection = new Connection(); - * $operationResponse = $repositoryManagerClient->updateConnection($connection); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $repositoryManagerClient->updateConnection($connection); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $repositoryManagerClient->resumeOperation($operationName, 'updateConnection'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param Connection $connection Required. The Connection to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. - * @type bool $allowMissing - * If set to true, and the connection is not found a new connection - * will be created. In this situation `update_mask` is ignored. - * The creation will succeed only if the input connection has all the - * necessary information (e.g a github_config with both user_oauth_token and - * installation_id properties). - * @type string $etag - * The current etag of the connection. - * If an etag is provided and does not match the current etag of the - * connection, update will be blocked and an ABORTED error will be returned. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateConnection($connection, array $optionalArgs = []) - { - $request = new UpdateConnectionRequest(); - $requestParamHeaders = []; - $request->setConnection($connection); - $requestParamHeaders['connection.name'] = $connection->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - if (isset($optionalArgs['etag'])) { - $request->setEtag($optionalArgs['etag']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateConnection', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $resource = 'resource'; - * $response = $repositoryManagerClient->getIamPolicy($resource); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $repositoryManagerClient->setIamPolicy($resource, $policy); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } - - /** - * Returns permissions that a caller has on the specified resource. If the - resource does not exist, this will return an empty set of - permissions, not a `NOT_FOUND` error. - - Note: This operation is designed to be used for building - permission-aware UIs and command-line tools, not for authorization - checking. This operation may "fail open" without warning. - * - * Sample code: - * ``` - * $repositoryManagerClient = new RepositoryManagerClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $repositoryManagerClient->testIamPermissions($resource, $permissions); - * } finally { - * $repositoryManagerClient->close(); - * } - * ``` - * - * @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[] $permissions 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). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.iam.v1.IAMPolicy')->wait(); - } -} diff --git a/owl-bot-staging/Build/v2/src/V2/RepositoryManagerClient.php b/owl-bot-staging/Build/v2/src/V2/RepositoryManagerClient.php deleted file mode 100644 index cbbd8a468d36..000000000000 --- a/owl-bot-staging/Build/v2/src/V2/RepositoryManagerClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.devtools.cloudbuild.v2.RepositoryManager' => [ - 'BatchCreateRepositories' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V2\BatchCreateRepositoriesResponse', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V2\Connection', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRepository' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V2\Repository', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRepository' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Build\V2\Connection', - 'metadataReturnType' => '\Google\Cloud\Build\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'connection.name', - 'fieldAccessors' => [ - 'getConnection', - 'getName', - ], - ], - ], - ], - 'FetchLinkableRepositories' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRepositories', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Build\V2\FetchLinkableRepositoriesResponse', - 'headerParams' => [ - [ - 'keyName' => 'connection', - 'fieldAccessors' => [ - 'getConnection', - ], - ], - ], - ], - 'FetchReadToken' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Build\V2\FetchReadTokenResponse', - 'headerParams' => [ - [ - 'keyName' => 'repository', - 'fieldAccessors' => [ - 'getRepository', - ], - ], - ], - ], - 'FetchReadWriteToken' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Build\V2\FetchReadWriteTokenResponse', - 'headerParams' => [ - [ - 'keyName' => 'repository', - 'fieldAccessors' => [ - 'getRepository', - ], - ], - ], - ], - 'GetConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Build\V2\Connection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetRepository' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Build\V2\Repository', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getConnections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Build\V2\ListConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListRepositories' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRepositories', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Build\V2\ListRepositoriesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - 'interfaceOverride' => 'google.iam.v1.IAMPolicy', - ], - 'templateMap' => [ - 'connection' => 'projects/{project}/locations/{location}/connections/{connection}', - 'location' => 'projects/{project}/locations/{location}', - 'repository' => 'projects/{project}/locations/{location}/connections/{connection}/repositories/{repository}', - 'secretVersion' => 'projects/{project}/secrets/{secret}/versions/{version}', - 'service' => 'projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}', - ], - ], - ], -]; diff --git a/owl-bot-staging/Build/v2/src/V2/resources/repository_manager_rest_client_config.php b/owl-bot-staging/Build/v2/src/V2/resources/repository_manager_rest_client_config.php deleted file mode 100644 index fe081aad713b..000000000000 --- a/owl-bot-staging/Build/v2/src/V2/resources/repository_manager_rest_client_config.php +++ /dev/null @@ -1,227 +0,0 @@ - [ - 'google.devtools.cloudbuild.v2.RepositoryManager' => [ - 'BatchCreateRepositories' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*/connections/*}/repositories:batchCreate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateConnection' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', - 'body' => 'connection', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'connection_id', - ], - ], - 'CreateRepository' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*/connections/*}/repositories', - 'body' => 'repository', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'repository_id', - ], - ], - 'DeleteConnection' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRepository' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*/repositories/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'FetchLinkableRepositories' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{connection=projects/*/locations/*/connections/*}:fetchLinkableRepositories', - 'placeholders' => [ - 'connection' => [ - 'getters' => [ - 'getConnection', - ], - ], - ], - ], - 'FetchReadToken' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{repository=projects/*/locations/*/connections/*/repositories/*}:accessReadToken', - 'body' => '*', - 'placeholders' => [ - 'repository' => [ - 'getters' => [ - 'getRepository', - ], - ], - ], - ], - 'FetchReadWriteToken' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{repository=projects/*/locations/*/connections/*/repositories/*}:accessReadWriteToken', - 'body' => '*', - 'placeholders' => [ - 'repository' => [ - 'getters' => [ - 'getRepository', - ], - ], - ], - ], - 'GetConnection' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetRepository' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/connections/*/repositories/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/connections', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListRepositories' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*/connections/*}/repositories', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateConnection' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{connection.name=projects/*/locations/*/connections/*}', - 'body' => 'connection', - 'placeholders' => [ - 'connection.name' => [ - 'getters' => [ - 'getConnection', - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{resource=projects/*/locations/*/connections/*}:getIamPolicy', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{resource=projects/*/locations/*/connections/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{resource=projects/*/locations/*/connections/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/Build/v2/tests/Unit/V2/RepositoryManagerClientTest.php b/owl-bot-staging/Build/v2/tests/Unit/V2/RepositoryManagerClientTest.php deleted file mode 100644 index 654b518f0e77..000000000000 --- a/owl-bot-staging/Build/v2/tests/Unit/V2/RepositoryManagerClientTest.php +++ /dev/null @@ -1,1467 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return RepositoryManagerClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new RepositoryManagerClient($options); - } - - /** @test */ - public function batchCreateRepositoriesTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/batchCreateRepositoriesTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BatchCreateRepositoriesResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/batchCreateRepositoriesTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $requests = []; - $response = $gapicClient->batchCreateRepositories($formattedParent, $requests); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/BatchCreateRepositories', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/batchCreateRepositoriesTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function batchCreateRepositoriesExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/batchCreateRepositoriesTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $requests = []; - $response = $gapicClient->batchCreateRepositories($formattedParent, $requests); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/batchCreateRepositoriesTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $disabled = true; - $reconciling = false; - $etag = 'etag3123477'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionId = 'connectionId-513204708'; - $response = $gapicClient->createConnection($formattedParent, $connection, $connectionId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/CreateConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $actualValue = $actualApiRequestObject->getConnectionId(); - $this->assertProtobufEquals($connectionId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $connection = new Connection(); - $connectionId = 'connectionId-513204708'; - $response = $gapicClient->createConnection($formattedParent, $connection, $connectionId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createRepositoryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createRepositoryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $remoteUri = 'remoteUri1041652211'; - $etag = 'etag3123477'; - $expectedResponse = new Repository(); - $expectedResponse->setName($name); - $expectedResponse->setRemoteUri($remoteUri); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createRepositoryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $repository = new Repository(); - $repositoryRemoteUri = 'repositoryRemoteUri792690460'; - $repository->setRemoteUri($repositoryRemoteUri); - $repositoryId = 'repositoryId1101683248'; - $response = $gapicClient->createRepository($formattedParent, $repository, $repositoryId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/CreateRepository', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getRepository(); - $this->assertProtobufEquals($repository, $actualValue); - $actualValue = $actualApiRequestObject->getRepositoryId(); - $this->assertProtobufEquals($repositoryId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createRepositoryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createRepositoryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createRepositoryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $repository = new Repository(); - $repositoryRemoteUri = 'repositoryRemoteUri792690460'; - $repository->setRemoteUri($repositoryRemoteUri); - $repositoryId = 'repositoryId1101683248'; - $response = $gapicClient->createRepository($formattedParent, $repository, $repositoryId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createRepositoryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->deleteConnection($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/DeleteConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->deleteConnection($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteRepositoryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteRepositoryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteRepositoryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - $response = $gapicClient->deleteRepository($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/DeleteRepository', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRepositoryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteRepositoryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteRepositoryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - $response = $gapicClient->deleteRepository($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRepositoryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function fetchLinkableRepositoriesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $repositoriesElement = new Repository(); - $repositories = [ - $repositoriesElement, - ]; - $expectedResponse = new FetchLinkableRepositoriesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRepositories($repositories); - $transport->addResponse($expectedResponse); - // Mock request - $formattedConnection = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->fetchLinkableRepositories($formattedConnection); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRepositories()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/FetchLinkableRepositories', $actualFuncCall); - $actualValue = $actualRequestObject->getConnection(); - $this->assertProtobufEquals($formattedConnection, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchLinkableRepositoriesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedConnection = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - try { - $gapicClient->fetchLinkableRepositories($formattedConnection); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchReadTokenTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $token = 'token110541305'; - $expectedResponse = new FetchReadTokenResponse(); - $expectedResponse->setToken($token); - $transport->addResponse($expectedResponse); - // Mock request - $formattedRepository = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - $response = $gapicClient->fetchReadToken($formattedRepository); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/FetchReadToken', $actualFuncCall); - $actualValue = $actualRequestObject->getRepository(); - $this->assertProtobufEquals($formattedRepository, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchReadTokenExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedRepository = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - try { - $gapicClient->fetchReadToken($formattedRepository); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchReadWriteTokenTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $token = 'token110541305'; - $expectedResponse = new FetchReadWriteTokenResponse(); - $expectedResponse->setToken($token); - $transport->addResponse($expectedResponse); - // Mock request - $formattedRepository = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - $response = $gapicClient->fetchReadWriteToken($formattedRepository); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/FetchReadWriteToken', $actualFuncCall); - $actualValue = $actualRequestObject->getRepository(); - $this->assertProtobufEquals($formattedRepository, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchReadWriteTokenExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedRepository = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - try { - $gapicClient->fetchReadWriteToken($formattedRepository); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $disabled = true; - $reconciling = false; - $etag = 'etag3123477'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name2); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->getConnection($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/GetConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getConnectionExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - try { - $gapicClient->getConnection($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRepositoryTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $remoteUri = 'remoteUri1041652211'; - $etag = 'etag3123477'; - $expectedResponse = new Repository(); - $expectedResponse->setName($name2); - $expectedResponse->setRemoteUri($remoteUri); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - $response = $gapicClient->getRepository($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/GetRepository', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRepositoryExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->repositoryName('[PROJECT]', '[LOCATION]', '[CONNECTION]', '[REPOSITORY]'); - try { - $gapicClient->getRepository($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $connectionsElement = new Connection(); - $connections = [ - $connectionsElement, - ]; - $expectedResponse = new ListConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setConnections($connections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listConnections($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/ListConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listConnectionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listConnections($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRepositoriesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $repositoriesElement = new Repository(); - $repositories = [ - $repositoriesElement, - ]; - $expectedResponse = new ListRepositoriesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRepositories($repositories); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - $response = $gapicClient->listRepositories($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRepositories()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/ListRepositories', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRepositoriesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->connectionName('[PROJECT]', '[LOCATION]', '[CONNECTION]'); - try { - $gapicClient->listRepositories($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateConnectionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $disabled = true; - $reconciling = false; - $etag2 = 'etag2-1293302904'; - $expectedResponse = new Connection(); - $expectedResponse->setName($name); - $expectedResponse->setDisabled($disabled); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setEtag($etag2); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $connection = new Connection(); - $response = $gapicClient->updateConnection($connection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.devtools.cloudbuild.v2.RepositoryManager/UpdateConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getConnection(); - $this->assertProtobufEquals($connection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateConnectionTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateConnectionExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $connection = new Connection(); - $response = $gapicClient->updateConnection($connection); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateConnectionTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.iam.v1.IAMPolicy/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateIssuanceConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateIssuanceConfig.php deleted file mode 100644 index 942ab73cecdc2410125a87d04df07f9d38318b32..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3473 zcmcInOLN;)6t0~|UpR&mli25L8&+mNa+~ZF_w|8xrkn7Z>4&k&d zw+>~#OJ&=!xTRZ$-10gd>d3maZ!?2BMOm(G$d5O+<>gvqdmL3=%X4(9$X(0o8nmPv zme(%n)ZwhdbTqk7Owy%J>0mDTR%5Q~5mTp{ZkZj{EeeMKCfTR1O>`>Po0WCSNtf2VUXKbrGbBh4FL0nf(oHjxiRp9}SK*o>lwG5`qE+-tnCYh@-lW|52_8hZc zk~_q3DOx)#+wn}DGs~2Hg$)dSW>yYt`m&R@g=j6wQLIfLKm<>1n4CH$G1MA$b%)v9 za+)ZrC|$~9*!?#%v!Pqx9P7w4L5zxWCdeh3J04AXmt}`?&oLK8+`fTc{G^_PWZ7ow z3Zq85LU+jlvm8Y^&g$4mKh;edR{hdiF&s4yd4?!n-eIh|&5#?M?Azz-iVEEOjD>iY z+wBH|Y-^A}2kBVVgMAFO? zVPU6YQQTtS48wGb*z%>d@IZPKGB&oc=3<-V(x^QoNdV#%xAv%+8}Kbkw_v!#3?zJR zQ2ZW+5zA>)M{6DChWs~$UsEvkx@cV+L!pum?CW!0bk3r@t&iBmfuO2 z(0T&H25C{l#a8qCpb@#bU=H=~gW{U7wQO?d(5HSoysU621dS{Gm^#^x#N)e`!}wu% zgXe}t++SZUj0Do<$U$&_2b{YPBL?eG0q=F;a4d2d!y8>OfrdH_dAy6oeAAvXvu!=q zY>F$3$#J0NM$pJmAlZSNd-PBvM%T}4cR!cGvs?3DL=OHPu&ea299a~8^1q}Z-#<_3 zWeO&feRT}9OPvE2uS{aPWapn>Exi7LB*_xjVk-zCD9NL1`EOzTJPRkpqy@OH6U|?c z!ilI(i;*}EcWj3pAoFz+W)a^!RpReNm0=j%!a&SQt&= zB?imY8vbt1fBeblpzzvEZ zZoNzw>SC2IR{d2z$*}d{Z$fcr?)OMY4Hy38#vh8QxbnYB-wli@im--X$NvmMIYmLa wvZ}t8Xwt(=7f2A(uSP)WUTYXtx%JU>ykLG9?B|JfzV9k8B!h*!2R(p)05poFSO5S3 diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateManager.php b/owl-bot-staging/CertificateManager/v1/proto/src/GPBMetadata/Google/Cloud/Certificatemanager/V1/CertificateManager.php deleted file mode 100644 index dc1c47a0d3eaf20f159a299101d3ffdd40428d61..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 16621 zcmd5@-ESOM74NQNJ3e+D=jO|Cnr6LesbeL(&9+h6P24bEukCH@*s|AFX%|-G-LXAn zy*r(mb-rYYFSQ8qA;bf!5Ktjipz^{4Jn{z+gea|qAOZwZQBfo$UXW0P1n1s6vwP=b z?V0r!k(aDz?mhRM-#ORLZfnJ27)piD`Pxtd(k&*jjyk zUD0Eu+LoqP6g?4(O)bQ3EaYR^sa$>(ry8}oUQ*JrjaqG^q9jX|TD_bsDY~hyt0fe< zC0FGQMNe*D6t5Po%L%p+KvmvS3{5U6v6;omdBv2=vMCp4n9M?k$}D6&G7GC0uK<)P zvSGx8yYqZSxCb%(r`6XgYAI%zvWfpar5Z)Gs+y`?QSYL;6R~x;$8VgqJE3+ZRVpSS!eyij+dbk2A%{ z8R5n{jj`gI6=c?clfnSqiX`jSlyxg8N2yl46iX~%EGcI#DV1haBx{YRum+v71~Ga= zR!Az;@77J5D;qbtAzSEOYlLlOV}xnDkPnD|Hv%W-RKpZ#&sb7kucM#Ii_oLVIzl!a ziABcxCeQs@iawIg!f2(2giJ#>!L>thjRZ1#a?ZLz4nv=YY+W>v9EYPgyPFUIcFC;W zRI0;WR3aIKo^`c?G&g*J{XGN+YkFDHi)(j=yXlqqHzF|X)z8pyafM`IK=8VOYIcqF zr;?UdyTwI9u$P>GLsjLrSrpWxD)*5i&|k0Wid@>1*D4C?+=Uty3UF*j5dpLD%D@5o z__5Hs#L!B@1wlpoVda8NP$vF!G&qB6nu>7MUSS^|IR%4)B1N^#+|oDMg=&%<^b0qc zbHd}uM8&^@`mbpC)b-QfwGIudHrFA~qi@(USOFL}nKAvT5!>~4yeArT$F(cM@RU+f ze3k2n``(Vgh$~*_W$pherQV9bDPI+>teS%%As7%|&CaZp4eu_DD`pm29x}PsVAz>k zD8df@X-9g!z|t!P&kDNkon9y|{!6sqlVQR-`$)1gKm>Itbgo2OghQ?YRBy^3D)?m$kVRf72C`_1x|S~Pf)W{&iz>gV&34+R!v=18d*5&da$(}OPzbp{Wt=n zyXbAD<|}Z*6+T6LJX6!GXW!-U8A`Fa6EaOJaN3imOpcwa*B!Y!!E*I7ToRNIl&ef; z{2%C3zl3$H*g2m*4a0(-EQuA0kt>y7gJZtKtb}gY6FjSF82e?l!{nA4@C4tN25n|} z4Pt&-?ohjptPi6Nld#!!=YZQ)_ z-5|P>HV=nAL#%{t3ud0JNZzM;wzjg$cU_*Q?XTNrj;e5)=V&WsJLm2{M&NLx(P4Mv zND_A&Y=={%yHU1X@+;jN-3D?V4l30$A5C{=yN||Ar77zhipdAy zNZVs|qlmo>1NW$Wqe-5G<2v8>D&=B{c6TZj#w5c%xZ**&7sPFD5hWS8^BwM`8^riu z4nu#Y*-oTOHFtn?O4(}N(J2S%6zVh4_&v>`5!NMmnn6Z)&%1)aXI+P$ioB*&478o@ zjIRV?62YFt9GlJ9n|uZa45hM;&qLaWEi>5qQ`2EZE~AWjE<#vo_A#;oy|(CnX5M62 z(Y|6&qS|t`h*{5C!{|-i#B+F_fJ2(HRTOA!xR3g%0l9KpQ+0*M9d&pB$aBzbl(364 zJb>c|Qv*|+qera-c;^1xB3T0eh)yrK#`-+ zTdr-%YL!=#OjI{n^?fWw8HD&4=zb)%^%x-7LpkJXim^27o6In&6L3ZF3J(k2g0j(U z62iyXkfq|gX_6}}=Lb`>VZGo5D6vfC@yMtH!T!RwN{IklxkYLT?GDiZ$#-C>ML{^V z%v$zK*jjKD2u0b%*CLvUFCx}!n2$8YU+cj7jzUV}YvgbVX8p+DkkdUH5)FEg(ha0J z8i|7)(ZjP!Vu>xmy+9)t-|wi%Zme6!uEvq__#ko|$Wm5XUbskAHmU6F3`5fNPEibQRhazMM29~6Jwm6rY&*gDwbmXsHFx(0Z+PmZ#!z}J2 zbvx#$HiIeoV|0WVjBi9>a2-*oBT-o%ppiJ3Qa?@wrum93{K1;Jwm-UA=8$7>csWnu zb$a6v^xNLZ-Izfy3~a&!2*H@*swI~K-=_6WVXvXm|Q`Wh!^7H&-E zsNi1c%1F{s)Z^!__$=(MBu2*K(!y$P8N-EZ+0-gZHIy>>+-i2HYvcm-i_gq{=%Vz? z$eBD2-P>{nnSzCDI{HE+{uC}u37_;s?^JeLTA9mZgdzmlshMmsBV}eWFw@%)B_m`T znM@)>eO4)%M)IEZYbV)g+b8eYKX=4;sW?_(-JQuEIAGq*2m_Yt%&w5xk^Wrd zp|lge!Ao*AMx41e19*@=I%2aY&HpBKZs7W%A+>`eRzEcBNf@y`qWO!!D;b~%!O zz`@O$VX_SkOKA+oC0eALrA>Te2ka?xt=*O8xfql=>w1gViviR(nR+CJeRoEt>_;%& zY7M5I4Wiq!qHkjn*DUWsMrk|=y_PMsw3wIjNZL!TrySDz;!)W=JCnW8&0HV<_W>Akw+>tng#YCxchMF5pA6!4xBia6 zckSExFNlg4Ry z4i0Z{lB#Fr}}>L&KgHPf|RPM!Cn%3x&1#8{5f*sr=K2H8a1dh09fL5g>&}PPGqHScL63utMML|;xhD+qR zkQ79-@r3pFPY)_yZ>i}v89 z@A0ghj<@5B^dTXO>Hg+{bk0jp^oE0?@NY&_XFXj2pCEnLJ@m!)+C&Os zfd5<@gLaR2#9wt79V#OHEf&b}J#@Yw#c`_xIltv}+weVT@>iS;%JEJ*HSK@i=Ye#| zpG5h_*+Zp@b(ZM9H0Ix1@?q8Y5mG;H3;}7&=>Z}AHHY+WO7`PdZfiJ}Z5c={fgW{n zu!V44EF^=2`V|D#k5of|+H!h8P~YUB&X4mr?Pwl`W9$zjaEwweb{L#{a1yAW;ycv_ zArR5EkYKU&G~=twbyzend z;M;eiaGVpS$E-le`_Hv4+kUEy$<2<6;%!+XA_vI)&=_)v#M@kHm3sSA^F2lC}sC_N}V(L&OJ?Mhu+dZfToD zRh-}CTQ{^dpF@1w+Pl&C4Er2Ek)faCC%g(IRxjSS2NkT3_QlVyEj(#GqR8`D&hxgoogle.cloud.certificatemanager.v1.Certificate - */ -class Certificate extends \Google\Protobuf\Internal\Message -{ - /** - * A user-defined name of the certificate. Certificate names must be unique - * globally and match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * One or more paragraphs of text description of a certificate. - * - * Generated from protobuf field string description = 8; - */ - protected $description = ''; - /** - * Output only. The creation timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Set of labels associated with a Certificate. - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - /** - * Output only. The list of Subject Alternative Names of dnsName type defined - * in the certificate (see RFC 5280 4.2.1.6). Managed certificates that - * haven't been provisioned yet have this field populated with a value of the - * managed.domains field. - * - * Generated from protobuf field repeated string san_dnsnames = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $san_dnsnames; - /** - * Output only. The PEM-encoded certificate chain. - * - * Generated from protobuf field string pem_certificate = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pem_certificate = ''; - /** - * Output only. The expiry timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Immutable. The scope of the certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.Scope scope = 12 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $scope = 0; - protected $type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * A user-defined name of the certificate. Certificate names must be unique - * globally and match pattern `projects/*/locations/*/certificates/*`. - * @type string $description - * One or more paragraphs of text description of a certificate. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a Certificate. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of a Certificate. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Set of labels associated with a Certificate. - * @type \Google\Cloud\CertificateManager\V1\Certificate\SelfManagedCertificate $self_managed - * If set, defines data of a self-managed certificate. - * @type \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate $managed - * If set, contains configuration and state of a managed certificate. - * @type array|\Google\Protobuf\Internal\RepeatedField $san_dnsnames - * Output only. The list of Subject Alternative Names of dnsName type defined - * in the certificate (see RFC 5280 4.2.1.6). Managed certificates that - * haven't been provisioned yet have this field populated with a value of the - * managed.domains field. - * @type string $pem_certificate - * Output only. The PEM-encoded certificate chain. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The expiry timestamp of a Certificate. - * @type int $scope - * Immutable. The scope of the certificate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A user-defined name of the certificate. Certificate names must be unique - * globally and match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * A user-defined name of the certificate. Certificate names must be unique - * globally and match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * One or more paragraphs of text description of a certificate. - * - * Generated from protobuf field string description = 8; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * One or more paragraphs of text description of a certificate. - * - * Generated from protobuf field string description = 8; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. The creation timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The creation timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The last update timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The last update timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Set of labels associated with a Certificate. - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Set of labels associated with a Certificate. - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * If set, defines data of a self-managed certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.SelfManagedCertificate self_managed = 5; - * @return \Google\Cloud\CertificateManager\V1\Certificate\SelfManagedCertificate|null - */ - public function getSelfManaged() - { - return $this->readOneof(5); - } - - public function hasSelfManaged() - { - return $this->hasOneof(5); - } - - /** - * If set, defines data of a self-managed certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.SelfManagedCertificate self_managed = 5; - * @param \Google\Cloud\CertificateManager\V1\Certificate\SelfManagedCertificate $var - * @return $this - */ - public function setSelfManaged($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\Certificate\SelfManagedCertificate::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * If set, contains configuration and state of a managed certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate managed = 11; - * @return \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate|null - */ - public function getManaged() - { - return $this->readOneof(11); - } - - public function hasManaged() - { - return $this->hasOneof(11); - } - - /** - * If set, contains configuration and state of a managed certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate managed = 11; - * @param \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate $var - * @return $this - */ - public function setManaged($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * Output only. The list of Subject Alternative Names of dnsName type defined - * in the certificate (see RFC 5280 4.2.1.6). Managed certificates that - * haven't been provisioned yet have this field populated with a value of the - * managed.domains field. - * - * Generated from protobuf field repeated string san_dnsnames = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSanDnsnames() - { - return $this->san_dnsnames; - } - - /** - * Output only. The list of Subject Alternative Names of dnsName type defined - * in the certificate (see RFC 5280 4.2.1.6). Managed certificates that - * haven't been provisioned yet have this field populated with a value of the - * managed.domains field. - * - * Generated from protobuf field repeated string san_dnsnames = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSanDnsnames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->san_dnsnames = $arr; - - return $this; - } - - /** - * Output only. The PEM-encoded certificate chain. - * - * Generated from protobuf field string pem_certificate = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPemCertificate() - { - return $this->pem_certificate; - } - - /** - * Output only. The PEM-encoded certificate chain. - * - * Generated from protobuf field string pem_certificate = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPemCertificate($var) - { - GPBUtil::checkString($var, True); - $this->pem_certificate = $var; - - return $this; - } - - /** - * Output only. The expiry timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExpireTime() - { - return $this->expire_time; - } - - public function hasExpireTime() - { - return isset($this->expire_time); - } - - public function clearExpireTime() - { - unset($this->expire_time); - } - - /** - * Output only. The expiry timestamp of a Certificate. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpireTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expire_time = $var; - - return $this; - } - - /** - * Immutable. The scope of the certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.Scope scope = 12 [(.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getScope() - { - return $this->scope; - } - - /** - * Immutable. The scope of the certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.Scope scope = 12 [(.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\Certificate\Scope::class); - $this->scope = $var; - - return $this; - } - - /** - * @return string - */ - public function getType() - { - return $this->whichOneof("type"); - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate.php deleted file mode 100644 index 36e90481af0b..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate.php +++ /dev/null @@ -1,296 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate - */ -class ManagedCertificate extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The domains for which a managed SSL certificate will be - * generated. Wildcard domains are only supported with DNS challenge - * resolution. - * - * Generated from protobuf field repeated string domains = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - private $domains; - /** - * Immutable. Authorizations that will be used for performing domain - * authorization. - * - * Generated from protobuf field repeated string dns_authorizations = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - */ - private $dns_authorizations; - /** - * Immutable. The resource name for a - * [CertificateIssuanceConfig][google.cloud.certificatemanager.v1.CertificateIssuanceConfig] - * used to configure private PKI certificates in the format - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * If this field is not set, the certificates will instead be publicly - * signed as documented at - * https://cloud.google.com/load-balancing/docs/ssl-certificates/google-managed-certs#caa. - * - * Generated from protobuf field string issuance_config = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - */ - protected $issuance_config = ''; - /** - * Output only. State of the managed certificate resource. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Information about issues with provisioning a Managed - * Certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue provisioning_issue = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $provisioning_issue = null; - /** - * Output only. Detailed state of the latest authorization attempt for each - * domain specified for managed certificate resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo authorization_attempt_info = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $authorization_attempt_info; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $domains - * Immutable. The domains for which a managed SSL certificate will be - * generated. Wildcard domains are only supported with DNS challenge - * resolution. - * @type array|\Google\Protobuf\Internal\RepeatedField $dns_authorizations - * Immutable. Authorizations that will be used for performing domain - * authorization. - * @type string $issuance_config - * Immutable. The resource name for a - * [CertificateIssuanceConfig][google.cloud.certificatemanager.v1.CertificateIssuanceConfig] - * used to configure private PKI certificates in the format - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * If this field is not set, the certificates will instead be publicly - * signed as documented at - * https://cloud.google.com/load-balancing/docs/ssl-certificates/google-managed-certs#caa. - * @type int $state - * Output only. State of the managed certificate resource. - * @type \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\ProvisioningIssue $provisioning_issue - * Output only. Information about issues with provisioning a Managed - * Certificate. - * @type array<\Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\AuthorizationAttemptInfo>|\Google\Protobuf\Internal\RepeatedField $authorization_attempt_info - * Output only. Detailed state of the latest authorization attempt for each - * domain specified for managed certificate resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The domains for which a managed SSL certificate will be - * generated. Wildcard domains are only supported with DNS challenge - * resolution. - * - * Generated from protobuf field repeated string domains = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDomains() - { - return $this->domains; - } - - /** - * Immutable. The domains for which a managed SSL certificate will be - * generated. Wildcard domains are only supported with DNS challenge - * resolution. - * - * Generated from protobuf field repeated string domains = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDomains($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->domains = $arr; - - return $this; - } - - /** - * Immutable. Authorizations that will be used for performing domain - * authorization. - * - * Generated from protobuf field repeated string dns_authorizations = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDnsAuthorizations() - { - return $this->dns_authorizations; - } - - /** - * Immutable. Authorizations that will be used for performing domain - * authorization. - * - * Generated from protobuf field repeated string dns_authorizations = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDnsAuthorizations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->dns_authorizations = $arr; - - return $this; - } - - /** - * Immutable. The resource name for a - * [CertificateIssuanceConfig][google.cloud.certificatemanager.v1.CertificateIssuanceConfig] - * used to configure private PKI certificates in the format - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * If this field is not set, the certificates will instead be publicly - * signed as documented at - * https://cloud.google.com/load-balancing/docs/ssl-certificates/google-managed-certs#caa. - * - * Generated from protobuf field string issuance_config = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @return string - */ - public function getIssuanceConfig() - { - return $this->issuance_config; - } - - /** - * Immutable. The resource name for a - * [CertificateIssuanceConfig][google.cloud.certificatemanager.v1.CertificateIssuanceConfig] - * used to configure private PKI certificates in the format - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * If this field is not set, the certificates will instead be publicly - * signed as documented at - * https://cloud.google.com/load-balancing/docs/ssl-certificates/google-managed-certs#caa. - * - * Generated from protobuf field string issuance_config = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setIssuanceConfig($var) - { - GPBUtil::checkString($var, True); - $this->issuance_config = $var; - - return $this; - } - - /** - * Output only. State of the managed certificate resource. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the managed certificate resource. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Information about issues with provisioning a Managed - * Certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue provisioning_issue = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\ProvisioningIssue|null - */ - public function getProvisioningIssue() - { - return $this->provisioning_issue; - } - - public function hasProvisioningIssue() - { - return isset($this->provisioning_issue); - } - - public function clearProvisioningIssue() - { - unset($this->provisioning_issue); - } - - /** - * Output only. Information about issues with provisioning a Managed - * Certificate. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue provisioning_issue = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\ProvisioningIssue $var - * @return $this - */ - public function setProvisioningIssue($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\ProvisioningIssue::class); - $this->provisioning_issue = $var; - - return $this; - } - - /** - * Output only. Detailed state of the latest authorization attempt for each - * domain specified for managed certificate resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo authorization_attempt_info = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAuthorizationAttemptInfo() - { - return $this->authorization_attempt_info; - } - - /** - * Output only. Detailed state of the latest authorization attempt for each - * domain specified for managed certificate resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo authorization_attempt_info = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\AuthorizationAttemptInfo>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAuthorizationAttemptInfo($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\AuthorizationAttemptInfo::class); - $this->authorization_attempt_info = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ManagedCertificate::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo.php deleted file mode 100644 index 7081bd62999f..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo.php +++ /dev/null @@ -1,185 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo - */ -class AuthorizationAttemptInfo extends \Google\Protobuf\Internal\Message -{ - /** - * Domain name of the authorization attempt. - * - * Generated from protobuf field string domain = 1; - */ - protected $domain = ''; - /** - * Output only. State of the domain for managed certificate issuance. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Reason for failure of the authorization attempt for the - * domain. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.FailureReason failure_reason = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $failure_reason = 0; - /** - * Output only. Human readable explanation for reaching the state. - * Provided to help address the configuration issues. Not guaranteed to be - * stable. For programmatic access use FailureReason enum. - * - * Generated from protobuf field string details = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $details = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $domain - * Domain name of the authorization attempt. - * @type int $state - * Output only. State of the domain for managed certificate issuance. - * @type int $failure_reason - * Output only. Reason for failure of the authorization attempt for the - * domain. - * @type string $details - * Output only. Human readable explanation for reaching the state. - * Provided to help address the configuration issues. Not guaranteed to be - * stable. For programmatic access use FailureReason enum. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Domain name of the authorization attempt. - * - * Generated from protobuf field string domain = 1; - * @return string - */ - public function getDomain() - { - return $this->domain; - } - - /** - * Domain name of the authorization attempt. - * - * Generated from protobuf field string domain = 1; - * @param string $var - * @return $this - */ - public function setDomain($var) - { - GPBUtil::checkString($var, True); - $this->domain = $var; - - return $this; - } - - /** - * Output only. State of the domain for managed certificate issuance. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the domain for managed certificate issuance. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\AuthorizationAttemptInfo\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Reason for failure of the authorization attempt for the - * domain. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.FailureReason failure_reason = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getFailureReason() - { - return $this->failure_reason; - } - - /** - * Output only. Reason for failure of the authorization attempt for the - * domain. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.FailureReason failure_reason = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setFailureReason($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\AuthorizationAttemptInfo\FailureReason::class); - $this->failure_reason = $var; - - return $this; - } - - /** - * Output only. Human readable explanation for reaching the state. - * Provided to help address the configuration issues. Not guaranteed to be - * stable. For programmatic access use FailureReason enum. - * - * Generated from protobuf field string details = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDetails() - { - return $this->details; - } - - /** - * Output only. Human readable explanation for reaching the state. - * Provided to help address the configuration issues. Not guaranteed to be - * stable. For programmatic access use FailureReason enum. - * - * Generated from protobuf field string details = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDetails($var) - { - GPBUtil::checkString($var, True); - $this->details = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AuthorizationAttemptInfo::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_AuthorizationAttemptInfo::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/FailureReason.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/FailureReason.php deleted file mode 100644 index 3cec790c0492..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/FailureReason.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.FailureReason - */ -class FailureReason -{ - /** - * FailureReason is unspecified. - * - * Generated from protobuf enum FAILURE_REASON_UNSPECIFIED = 0; - */ - const FAILURE_REASON_UNSPECIFIED = 0; - /** - * There was a problem with the user's DNS or load balancer - * configuration for this domain. - * - * Generated from protobuf enum CONFIG = 1; - */ - const CONFIG = 1; - /** - * Certificate issuance forbidden by an explicit CAA record for the - * domain or a failure to check CAA records for the domain. - * - * Generated from protobuf enum CAA = 2; - */ - const CAA = 2; - /** - * Reached a CA or internal rate-limit for the domain, - * e.g. for certificates per top-level private domain. - * - * Generated from protobuf enum RATE_LIMITED = 3; - */ - const RATE_LIMITED = 3; - - private static $valueToName = [ - self::FAILURE_REASON_UNSPECIFIED => 'FAILURE_REASON_UNSPECIFIED', - self::CONFIG => 'CONFIG', - self::CAA => 'CAA', - self::RATE_LIMITED => 'RATE_LIMITED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FailureReason::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_AuthorizationAttemptInfo_FailureReason::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/State.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/State.php deleted file mode 100644 index a7c412566e2e..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/AuthorizationAttemptInfo/State.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.AuthorizationAttemptInfo.State - */ -class State -{ - /** - * State is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Certificate provisioning for this domain is under way. GCP will - * attempt to authorize the domain. - * - * Generated from protobuf enum AUTHORIZING = 1; - */ - const AUTHORIZING = 1; - /** - * A managed certificate can be provisioned, no issues for this domain. - * - * Generated from protobuf enum AUTHORIZED = 6; - */ - const AUTHORIZED = 6; - /** - * Attempt to authorize the domain failed. This prevents the Managed - * Certificate from being issued. - * See `failure_reason` and `details` fields for more information. - * - * Generated from protobuf enum FAILED = 7; - */ - const FAILED = 7; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::AUTHORIZING => 'AUTHORIZING', - self::AUTHORIZED => 'AUTHORIZED', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_AuthorizationAttemptInfo_State::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue.php deleted file mode 100644 index 298111d31843..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue - */ -class ProvisioningIssue extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Reason for provisioning failures. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue.Reason reason = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $reason = 0; - /** - * Output only. Human readable explanation about the issue. Provided to - * help address the configuration issues. Not guaranteed to be stable. For - * programmatic access use Reason enum. - * - * Generated from protobuf field string details = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $details = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $reason - * Output only. Reason for provisioning failures. - * @type string $details - * Output only. Human readable explanation about the issue. Provided to - * help address the configuration issues. Not guaranteed to be stable. For - * programmatic access use Reason enum. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Reason for provisioning failures. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue.Reason reason = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getReason() - { - return $this->reason; - } - - /** - * Output only. Reason for provisioning failures. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue.Reason reason = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setReason($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\Certificate\ManagedCertificate\ProvisioningIssue\Reason::class); - $this->reason = $var; - - return $this; - } - - /** - * Output only. Human readable explanation about the issue. Provided to - * help address the configuration issues. Not guaranteed to be stable. For - * programmatic access use Reason enum. - * - * Generated from protobuf field string details = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDetails() - { - return $this->details; - } - - /** - * Output only. Human readable explanation about the issue. Provided to - * help address the configuration issues. Not guaranteed to be stable. For - * programmatic access use Reason enum. - * - * Generated from protobuf field string details = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDetails($var) - { - GPBUtil::checkString($var, True); - $this->details = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ProvisioningIssue::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_ProvisioningIssue::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue/Reason.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue/Reason.php deleted file mode 100644 index fead58541b1c..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/ProvisioningIssue/Reason.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.ProvisioningIssue.Reason - */ -class Reason -{ - /** - * Reason is unspecified. - * - * Generated from protobuf enum REASON_UNSPECIFIED = 0; - */ - const REASON_UNSPECIFIED = 0; - /** - * Certificate provisioning failed due to an issue with one or more of - * the domains on the certificate. - * For details of which domains failed, consult the - * `authorization_attempt_info` field. - * - * Generated from protobuf enum AUTHORIZATION_ISSUE = 1; - */ - const AUTHORIZATION_ISSUE = 1; - /** - * Exceeded Certificate Authority quotas or internal rate limits of the - * system. Provisioning may take longer to complete. - * - * Generated from protobuf enum RATE_LIMITED = 2; - */ - const RATE_LIMITED = 2; - - private static $valueToName = [ - self::REASON_UNSPECIFIED => 'REASON_UNSPECIFIED', - self::AUTHORIZATION_ISSUE => 'AUTHORIZATION_ISSUE', - self::RATE_LIMITED => 'RATE_LIMITED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Reason::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_ProvisioningIssue_Reason::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/State.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/State.php deleted file mode 100644 index 8cfa7a463eb8..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/ManagedCertificate/State.php +++ /dev/null @@ -1,77 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.ManagedCertificate.State - */ -class State -{ - /** - * State is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Certificate Manager attempts to provision or renew the certificate. - * If the process takes longer than expected, consult the - * `provisioning_issue` field. - * - * Generated from protobuf enum PROVISIONING = 1; - */ - const PROVISIONING = 1; - /** - * Multiple certificate provisioning attempts failed and Certificate - * Manager gave up. To try again, delete and create a new managed - * Certificate resource. - * For details see the `provisioning_issue` field. - * - * Generated from protobuf enum FAILED = 2; - */ - const FAILED = 2; - /** - * The certificate management is working, and a certificate has been - * provisioned. - * - * Generated from protobuf enum ACTIVE = 3; - */ - const ACTIVE = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PROVISIONING => 'PROVISIONING', - self::FAILED => 'FAILED', - self::ACTIVE => 'ACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\CertificateManager\V1\Certificate_ManagedCertificate_State::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/Scope.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/Scope.php deleted file mode 100644 index 73756db3d0df..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/Scope.php +++ /dev/null @@ -1,63 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.Scope - */ -class Scope -{ - /** - * Certificates with default scope are served from core Google data centers. - * If unsure, choose this option. - * - * Generated from protobuf enum DEFAULT = 0; - */ - const PBDEFAULT = 0; - /** - * Certificates with scope EDGE_CACHE are special-purposed certificates, - * served from non-core Google data centers. - * - * Generated from protobuf enum EDGE_CACHE = 1; - */ - const EDGE_CACHE = 1; - - private static $valueToName = [ - self::PBDEFAULT => 'DEFAULT', - self::EDGE_CACHE => 'EDGE_CACHE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Scope::class, \Google\Cloud\CertificateManager\V1\Certificate_Scope::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/SelfManagedCertificate.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/SelfManagedCertificate.php deleted file mode 100644 index 86ec18a91142..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/Certificate/SelfManagedCertificate.php +++ /dev/null @@ -1,110 +0,0 @@ -google.cloud.certificatemanager.v1.Certificate.SelfManagedCertificate - */ -class SelfManagedCertificate extends \Google\Protobuf\Internal\Message -{ - /** - * Input only. The PEM-encoded certificate chain. - * Leaf certificate comes first, followed by intermediate ones if any. - * - * Generated from protobuf field string pem_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY]; - */ - protected $pem_certificate = ''; - /** - * Input only. The PEM-encoded private key of the leaf certificate. - * - * Generated from protobuf field string pem_private_key = 2 [(.google.api.field_behavior) = INPUT_ONLY]; - */ - protected $pem_private_key = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $pem_certificate - * Input only. The PEM-encoded certificate chain. - * Leaf certificate comes first, followed by intermediate ones if any. - * @type string $pem_private_key - * Input only. The PEM-encoded private key of the leaf certificate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Input only. The PEM-encoded certificate chain. - * Leaf certificate comes first, followed by intermediate ones if any. - * - * Generated from protobuf field string pem_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY]; - * @return string - */ - public function getPemCertificate() - { - return $this->pem_certificate; - } - - /** - * Input only. The PEM-encoded certificate chain. - * Leaf certificate comes first, followed by intermediate ones if any. - * - * Generated from protobuf field string pem_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPemCertificate($var) - { - GPBUtil::checkString($var, True); - $this->pem_certificate = $var; - - return $this; - } - - /** - * Input only. The PEM-encoded private key of the leaf certificate. - * - * Generated from protobuf field string pem_private_key = 2 [(.google.api.field_behavior) = INPUT_ONLY]; - * @return string - */ - public function getPemPrivateKey() - { - return $this->pem_private_key; - } - - /** - * Input only. The PEM-encoded private key of the leaf certificate. - * - * Generated from protobuf field string pem_private_key = 2 [(.google.api.field_behavior) = INPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPemPrivateKey($var) - { - GPBUtil::checkString($var, True); - $this->pem_private_key = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SelfManagedCertificate::class, \Google\Cloud\CertificateManager\V1\Certificate_SelfManagedCertificate::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig.php deleted file mode 100644 index 5152f1515769..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig.php +++ /dev/null @@ -1,399 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateIssuanceConfig - */ -class CertificateIssuanceConfig extends \Google\Protobuf\Internal\Message -{ - /** - * A user-defined name of the certificate issuance config. - * CertificateIssuanceConfig names must be unique globally and match pattern - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. The creation timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Set of labels associated with a CertificateIssuanceConfig. - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - /** - * One or more paragraphs of text description of a CertificateIssuanceConfig. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * Required. The CA that issues the workload certificate. It includes the CA - * address, type, authentication to CA service, etc. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig certificate_authority_config = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_authority_config = null; - /** - * Required. Workload certificate lifetime requested. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lifetime = null; - /** - * Required. Specifies the percentage of elapsed time of the certificate - * lifetime to wait before renewing the certificate. Must be a number between - * 1-99, inclusive. - * - * Generated from protobuf field int32 rotation_window_percentage = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $rotation_window_percentage = 0; - /** - * Required. The key algorithm to use when generating the private key. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.KeyAlgorithm key_algorithm = 9 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key_algorithm = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * A user-defined name of the certificate issuance config. - * CertificateIssuanceConfig names must be unique globally and match pattern - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a CertificateIssuanceConfig. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of a CertificateIssuanceConfig. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Set of labels associated with a CertificateIssuanceConfig. - * @type string $description - * One or more paragraphs of text description of a CertificateIssuanceConfig. - * @type \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig $certificate_authority_config - * Required. The CA that issues the workload certificate. It includes the CA - * address, type, authentication to CA service, etc. - * @type \Google\Protobuf\Duration $lifetime - * Required. Workload certificate lifetime requested. - * @type int $rotation_window_percentage - * Required. Specifies the percentage of elapsed time of the certificate - * lifetime to wait before renewing the certificate. Must be a number between - * 1-99, inclusive. - * @type int $key_algorithm - * Required. The key algorithm to use when generating the private key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * A user-defined name of the certificate issuance config. - * CertificateIssuanceConfig names must be unique globally and match pattern - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * A user-defined name of the certificate issuance config. - * CertificateIssuanceConfig names must be unique globally and match pattern - * `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The creation timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The creation timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The last update timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The last update timestamp of a CertificateIssuanceConfig. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Set of labels associated with a CertificateIssuanceConfig. - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Set of labels associated with a CertificateIssuanceConfig. - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * One or more paragraphs of text description of a CertificateIssuanceConfig. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * One or more paragraphs of text description of a CertificateIssuanceConfig. - * - * Generated from protobuf field string description = 5; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. The CA that issues the workload certificate. It includes the CA - * address, type, authentication to CA service, etc. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig certificate_authority_config = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig|null - */ - public function getCertificateAuthorityConfig() - { - return $this->certificate_authority_config; - } - - public function hasCertificateAuthorityConfig() - { - return isset($this->certificate_authority_config); - } - - public function clearCertificateAuthorityConfig() - { - unset($this->certificate_authority_config); - } - - /** - * Required. The CA that issues the workload certificate. It includes the CA - * address, type, authentication to CA service, etc. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig certificate_authority_config = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig $var - * @return $this - */ - public function setCertificateAuthorityConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig::class); - $this->certificate_authority_config = $var; - - return $this; - } - - /** - * Required. Workload certificate lifetime requested. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Duration|null - */ - public function getLifetime() - { - return $this->lifetime; - } - - public function hasLifetime() - { - return isset($this->lifetime); - } - - public function clearLifetime() - { - unset($this->lifetime); - } - - /** - * Required. Workload certificate lifetime requested. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->lifetime = $var; - - return $this; - } - - /** - * Required. Specifies the percentage of elapsed time of the certificate - * lifetime to wait before renewing the certificate. Must be a number between - * 1-99, inclusive. - * - * Generated from protobuf field int32 rotation_window_percentage = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getRotationWindowPercentage() - { - return $this->rotation_window_percentage; - } - - /** - * Required. Specifies the percentage of elapsed time of the certificate - * lifetime to wait before renewing the certificate. Must be a number between - * 1-99, inclusive. - * - * Generated from protobuf field int32 rotation_window_percentage = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setRotationWindowPercentage($var) - { - GPBUtil::checkInt32($var); - $this->rotation_window_percentage = $var; - - return $this; - } - - /** - * Required. The key algorithm to use when generating the private key. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.KeyAlgorithm key_algorithm = 9 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getKeyAlgorithm() - { - return $this->key_algorithm; - } - - /** - * Required. The key algorithm to use when generating the private key. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.KeyAlgorithm key_algorithm = 9 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setKeyAlgorithm($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\KeyAlgorithm::class); - $this->key_algorithm = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig.php deleted file mode 100644 index e060679a5ed1..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig - */ -class CertificateAuthorityConfig extends \Google\Protobuf\Internal\Message -{ - protected $kind; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig\CertificateAuthorityServiceConfig $certificate_authority_service_config - * Defines a CertificateAuthorityServiceConfig. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Defines a CertificateAuthorityServiceConfig. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig.CertificateAuthorityServiceConfig certificate_authority_service_config = 1; - * @return \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig\CertificateAuthorityServiceConfig|null - */ - public function getCertificateAuthorityServiceConfig() - { - return $this->readOneof(1); - } - - public function hasCertificateAuthorityServiceConfig() - { - return $this->hasOneof(1); - } - - /** - * Defines a CertificateAuthorityServiceConfig. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig.CertificateAuthorityServiceConfig certificate_authority_service_config = 1; - * @param \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig\CertificateAuthorityServiceConfig $var - * @return $this - */ - public function setCertificateAuthorityServiceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig\CertificateAuthorityConfig\CertificateAuthorityServiceConfig::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getKind() - { - return $this->whichOneof("kind"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CertificateAuthorityConfig::class, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig_CertificateAuthorityConfig::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig/CertificateAuthorityServiceConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig/CertificateAuthorityServiceConfig.php deleted file mode 100644 index caafaa5e49a2..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/CertificateAuthorityConfig/CertificateAuthorityServiceConfig.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateIssuanceConfig.CertificateAuthorityConfig.CertificateAuthorityServiceConfig - */ -class CertificateAuthorityServiceConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A CA pool resource used to issue a certificate. - * The CA pool string has a relative resource path following the form - * "projects/{project}/locations/{location}/caPools/{ca_pool}". - * - * Generated from protobuf field string ca_pool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $ca_pool = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ca_pool - * Required. A CA pool resource used to issue a certificate. - * The CA pool string has a relative resource path following the form - * "projects/{project}/locations/{location}/caPools/{ca_pool}". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. A CA pool resource used to issue a certificate. - * The CA pool string has a relative resource path following the form - * "projects/{project}/locations/{location}/caPools/{ca_pool}". - * - * Generated from protobuf field string ca_pool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getCaPool() - { - return $this->ca_pool; - } - - /** - * Required. A CA pool resource used to issue a certificate. - * The CA pool string has a relative resource path following the form - * "projects/{project}/locations/{location}/caPools/{ca_pool}". - * - * Generated from protobuf field string ca_pool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setCaPool($var) - { - GPBUtil::checkString($var, True); - $this->ca_pool = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CertificateAuthorityServiceConfig::class, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig_CertificateAuthorityConfig_CertificateAuthorityServiceConfig::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/KeyAlgorithm.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/KeyAlgorithm.php deleted file mode 100644 index 71f63a4297e3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig/KeyAlgorithm.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateIssuanceConfig.KeyAlgorithm - */ -class KeyAlgorithm -{ - /** - * Unspecified key algorithm. - * - * Generated from protobuf enum KEY_ALGORITHM_UNSPECIFIED = 0; - */ - const KEY_ALGORITHM_UNSPECIFIED = 0; - /** - * Specifies RSA with a 2048-bit modulus. - * - * Generated from protobuf enum RSA_2048 = 1; - */ - const RSA_2048 = 1; - /** - * Specifies ECDSA with curve P256. - * - * Generated from protobuf enum ECDSA_P256 = 4; - */ - const ECDSA_P256 = 4; - - private static $valueToName = [ - self::KEY_ALGORITHM_UNSPECIFIED => 'KEY_ALGORITHM_UNSPECIFIED', - self::RSA_2048 => 'RSA_2048', - self::ECDSA_P256 => 'ECDSA_P256', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(KeyAlgorithm::class, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig_KeyAlgorithm::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_CertificateAuthorityConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_CertificateAuthorityConfig.php deleted file mode 100644 index 7c23568dd114..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateIssuanceConfig_CertificateAuthorityConfig.php +++ /dev/null @@ -1,16 +0,0 @@ -_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificates', - $argument, - ['\Google\Cloud\CertificateManager\V1\ListCertificatesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single Certificate. - * @param \Google\Cloud\CertificateManager\V1\GetCertificateRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetCertificate(\Google\Cloud\CertificateManager\V1\GetCertificateRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificate', - $argument, - ['\Google\Cloud\CertificateManager\V1\Certificate', 'decode'], - $metadata, $options); - } - - /** - * Creates a new Certificate in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\CreateCertificateRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateCertificate(\Google\Cloud\CertificateManager\V1\CreateCertificateRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificate', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a Certificate. - * @param \Google\Cloud\CertificateManager\V1\UpdateCertificateRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateCertificate(\Google\Cloud\CertificateManager\V1\UpdateCertificateRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificate', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single Certificate. - * @param \Google\Cloud\CertificateManager\V1\DeleteCertificateRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteCertificate(\Google\Cloud\CertificateManager\V1\DeleteCertificateRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificate', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists CertificateMaps in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\ListCertificateMapsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListCertificateMaps(\Google\Cloud\CertificateManager\V1\ListCertificateMapsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateMaps', - $argument, - ['\Google\Cloud\CertificateManager\V1\ListCertificateMapsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single CertificateMap. - * @param \Google\Cloud\CertificateManager\V1\GetCertificateMapRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetCertificateMap(\Google\Cloud\CertificateManager\V1\GetCertificateMapRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateMap', - $argument, - ['\Google\Cloud\CertificateManager\V1\CertificateMap', 'decode'], - $metadata, $options); - } - - /** - * Creates a new CertificateMap in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\CreateCertificateMapRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateCertificateMap(\Google\Cloud\CertificateManager\V1\CreateCertificateMapRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateMap', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a CertificateMap. - * @param \Google\Cloud\CertificateManager\V1\UpdateCertificateMapRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateCertificateMap(\Google\Cloud\CertificateManager\V1\UpdateCertificateMapRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificateMap', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single CertificateMap. A Certificate Map can't be deleted - * if it contains Certificate Map Entries. Remove all the entries from - * the map before calling this method. - * @param \Google\Cloud\CertificateManager\V1\DeleteCertificateMapRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteCertificateMap(\Google\Cloud\CertificateManager\V1\DeleteCertificateMapRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateMap', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists CertificateMapEntries in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListCertificateMapEntries(\Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateMapEntries', - $argument, - ['\Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single CertificateMapEntry. - * @param \Google\Cloud\CertificateManager\V1\GetCertificateMapEntryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetCertificateMapEntry(\Google\Cloud\CertificateManager\V1\GetCertificateMapEntryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateMapEntry', - $argument, - ['\Google\Cloud\CertificateManager\V1\CertificateMapEntry', 'decode'], - $metadata, $options); - } - - /** - * Creates a new CertificateMapEntry in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\CreateCertificateMapEntryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateCertificateMapEntry(\Google\Cloud\CertificateManager\V1\CreateCertificateMapEntryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateMapEntry', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a CertificateMapEntry. - * @param \Google\Cloud\CertificateManager\V1\UpdateCertificateMapEntryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateCertificateMapEntry(\Google\Cloud\CertificateManager\V1\UpdateCertificateMapEntryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificateMapEntry', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single CertificateMapEntry. - * @param \Google\Cloud\CertificateManager\V1\DeleteCertificateMapEntryRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteCertificateMapEntry(\Google\Cloud\CertificateManager\V1\DeleteCertificateMapEntryRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateMapEntry', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists DnsAuthorizations in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListDnsAuthorizations(\Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/ListDnsAuthorizations', - $argument, - ['\Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single DnsAuthorization. - * @param \Google\Cloud\CertificateManager\V1\GetDnsAuthorizationRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetDnsAuthorization(\Google\Cloud\CertificateManager\V1\GetDnsAuthorizationRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/GetDnsAuthorization', - $argument, - ['\Google\Cloud\CertificateManager\V1\DnsAuthorization', 'decode'], - $metadata, $options); - } - - /** - * Creates a new DnsAuthorization in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\CreateDnsAuthorizationRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateDnsAuthorization(\Google\Cloud\CertificateManager\V1\CreateDnsAuthorizationRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/CreateDnsAuthorization', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a DnsAuthorization. - * @param \Google\Cloud\CertificateManager\V1\UpdateDnsAuthorizationRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateDnsAuthorization(\Google\Cloud\CertificateManager\V1\UpdateDnsAuthorizationRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/UpdateDnsAuthorization', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single DnsAuthorization. - * @param \Google\Cloud\CertificateManager\V1\DeleteDnsAuthorizationRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteDnsAuthorization(\Google\Cloud\CertificateManager\V1\DeleteDnsAuthorizationRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/DeleteDnsAuthorization', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Lists CertificateIssuanceConfigs in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListCertificateIssuanceConfigs(\Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateIssuanceConfigs', - $argument, - ['\Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single CertificateIssuanceConfig. - * @param \Google\Cloud\CertificateManager\V1\GetCertificateIssuanceConfigRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetCertificateIssuanceConfig(\Google\Cloud\CertificateManager\V1\GetCertificateIssuanceConfigRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateIssuanceConfig', - $argument, - ['\Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig', 'decode'], - $metadata, $options); - } - - /** - * Creates a new CertificateIssuanceConfig in a given project and location. - * @param \Google\Cloud\CertificateManager\V1\CreateCertificateIssuanceConfigRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateCertificateIssuanceConfig(\Google\Cloud\CertificateManager\V1\CreateCertificateIssuanceConfigRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateIssuanceConfig', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single CertificateIssuanceConfig. - * @param \Google\Cloud\CertificateManager\V1\DeleteCertificateIssuanceConfigRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteCertificateIssuanceConfig(\Google\Cloud\CertificateManager\V1\DeleteCertificateIssuanceConfigRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateIssuanceConfig', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap.php deleted file mode 100644 index 6d10dbd295df..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap.php +++ /dev/null @@ -1,273 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateMap - */ -class CertificateMap extends \Google\Protobuf\Internal\Message -{ - /** - * A user-defined name of the Certificate Map. Certificate Map names must be - * unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * One or more paragraphs of text description of a certificate map. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * Output only. The creation timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The update timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Set of labels associated with a Certificate Map. - * - * Generated from protobuf field map labels = 3; - */ - private $labels; - /** - * Output only. A list of GCLB targets that use this Certificate Map. - * A Target Proxy is only present on this list if it's attached to a - * Forwarding Rule. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget gclb_targets = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $gclb_targets; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * A user-defined name of the Certificate Map. Certificate Map names must be - * unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*`. - * @type string $description - * One or more paragraphs of text description of a certificate map. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a Certificate Map. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The update timestamp of a Certificate Map. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Set of labels associated with a Certificate Map. - * @type array<\Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget>|\Google\Protobuf\Internal\RepeatedField $gclb_targets - * Output only. A list of GCLB targets that use this Certificate Map. - * A Target Proxy is only present on this list if it's attached to a - * Forwarding Rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A user-defined name of the Certificate Map. Certificate Map names must be - * unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * A user-defined name of the Certificate Map. Certificate Map names must be - * unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * One or more paragraphs of text description of a certificate map. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * One or more paragraphs of text description of a certificate map. - * - * Generated from protobuf field string description = 5; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. The creation timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The creation timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The update timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The update timestamp of a Certificate Map. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Set of labels associated with a Certificate Map. - * - * Generated from protobuf field map labels = 3; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Set of labels associated with a Certificate Map. - * - * Generated from protobuf field map labels = 3; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Output only. A list of GCLB targets that use this Certificate Map. - * A Target Proxy is only present on this list if it's attached to a - * Forwarding Rule. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget gclb_targets = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGclbTargets() - { - return $this->gclb_targets; - } - - /** - * Output only. A list of GCLB targets that use this Certificate Map. - * A Target Proxy is only present on this list if it's attached to a - * Forwarding Rule. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget gclb_targets = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGclbTargets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget::class); - $this->gclb_targets = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget.php deleted file mode 100644 index 59c43861885a..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget.php +++ /dev/null @@ -1,161 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateMap.GclbTarget - */ -class GclbTarget extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. IP configurations for this Target Proxy where the - * Certificate Map is serving. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget.IpConfig ip_configs = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $ip_configs; - protected $target_proxy; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $target_https_proxy - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetHttpsProxies/*`. - * @type string $target_ssl_proxy - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetSslProxies/*`. - * @type array<\Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget\IpConfig>|\Google\Protobuf\Internal\RepeatedField $ip_configs - * Output only. IP configurations for this Target Proxy where the - * Certificate Map is serving. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetHttpsProxies/*`. - * - * Generated from protobuf field string target_https_proxy = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTargetHttpsProxy() - { - return $this->readOneof(1); - } - - public function hasTargetHttpsProxy() - { - return $this->hasOneof(1); - } - - /** - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetHttpsProxies/*`. - * - * Generated from protobuf field string target_https_proxy = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTargetHttpsProxy($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetSslProxies/*`. - * - * Generated from protobuf field string target_ssl_proxy = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTargetSslProxy() - { - return $this->readOneof(3); - } - - public function hasTargetSslProxy() - { - return $this->hasOneof(3); - } - - /** - * Output only. This field returns the resource name in the following - * format: - * `//compute.googleapis.com/projects/*/global/targetSslProxies/*`. - * - * Generated from protobuf field string target_ssl_proxy = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTargetSslProxy($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Output only. IP configurations for this Target Proxy where the - * Certificate Map is serving. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget.IpConfig ip_configs = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIpConfigs() - { - return $this->ip_configs; - } - - /** - * Output only. IP configurations for this Target Proxy where the - * Certificate Map is serving. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap.GclbTarget.IpConfig ip_configs = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget\IpConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIpConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\CertificateMap\GclbTarget\IpConfig::class); - $this->ip_configs = $arr; - - return $this; - } - - /** - * @return string - */ - public function getTargetProxy() - { - return $this->whichOneof("target_proxy"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(GclbTarget::class, \Google\Cloud\CertificateManager\V1\CertificateMap_GclbTarget::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget/IpConfig.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget/IpConfig.php deleted file mode 100644 index ab5ed740ef57..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMap/GclbTarget/IpConfig.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateMap.GclbTarget.IpConfig - */ -class IpConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. An external IP address. - * - * Generated from protobuf field string ip_address = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $ip_address = ''; - /** - * Output only. Ports. - * - * Generated from protobuf field repeated uint32 ports = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $ports; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ip_address - * Output only. An external IP address. - * @type array|\Google\Protobuf\Internal\RepeatedField $ports - * Output only. Ports. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Output only. An external IP address. - * - * Generated from protobuf field string ip_address = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getIpAddress() - { - return $this->ip_address; - } - - /** - * Output only. An external IP address. - * - * Generated from protobuf field string ip_address = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setIpAddress($var) - { - GPBUtil::checkString($var, True); - $this->ip_address = $var; - - return $this; - } - - /** - * Output only. Ports. - * - * Generated from protobuf field repeated uint32 ports = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPorts() - { - return $this->ports; - } - - /** - * Output only. Ports. - * - * Generated from protobuf field repeated uint32 ports = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::UINT32); - $this->ports = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(IpConfig::class, \Google\Cloud\CertificateManager\V1\CertificateMap_GclbTarget_IpConfig::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry.php deleted file mode 100644 index 4c6b3f1ada5f..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry.php +++ /dev/null @@ -1,388 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateMapEntry - */ -class CertificateMapEntry extends \Google\Protobuf\Internal\Message -{ - /** - * A user-defined name of the Certificate Map Entry. Certificate Map Entry - * names must be unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * One or more paragraphs of text description of a certificate map entry. - * - * Generated from protobuf field string description = 9; - */ - protected $description = ''; - /** - * Output only. The creation timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The update timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Set of labels associated with a Certificate Map Entry. - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - /** - * A set of Certificates defines for the given `hostname`. There can be - * defined up to four certificates in each Certificate Map Entry. Each - * certificate must match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field repeated string certificates = 7 [(.google.api.resource_reference) = { - */ - private $certificates; - /** - * Output only. A serving state of this Certificate Map Entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.ServingState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - protected $match; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * A user-defined name of the Certificate Map Entry. Certificate Map Entry - * names must be unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * @type string $description - * One or more paragraphs of text description of a certificate map entry. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a Certificate Map Entry. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The update timestamp of a Certificate Map Entry. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Set of labels associated with a Certificate Map Entry. - * @type string $hostname - * A Hostname (FQDN, e.g. `example.com`) or a wildcard hostname expression - * (`*.example.com`) for a set of hostnames with common suffix. Used as - * Server Name Indication (SNI) for selecting a proper certificate. - * @type int $matcher - * A predefined matcher for particular cases, other than SNI selection. - * @type array|\Google\Protobuf\Internal\RepeatedField $certificates - * A set of Certificates defines for the given `hostname`. There can be - * defined up to four certificates in each Certificate Map Entry. Each - * certificate must match pattern `projects/*/locations/*/certificates/*`. - * @type int $state - * Output only. A serving state of this Certificate Map Entry. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A user-defined name of the Certificate Map Entry. Certificate Map Entry - * names must be unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * A user-defined name of the Certificate Map Entry. Certificate Map Entry - * names must be unique globally and match pattern - * `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * One or more paragraphs of text description of a certificate map entry. - * - * Generated from protobuf field string description = 9; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * One or more paragraphs of text description of a certificate map entry. - * - * Generated from protobuf field string description = 9; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. The creation timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The creation timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The update timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The update timestamp of a Certificate Map Entry. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Set of labels associated with a Certificate Map Entry. - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Set of labels associated with a Certificate Map Entry. - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * A Hostname (FQDN, e.g. `example.com`) or a wildcard hostname expression - * (`*.example.com`) for a set of hostnames with common suffix. Used as - * Server Name Indication (SNI) for selecting a proper certificate. - * - * Generated from protobuf field string hostname = 5; - * @return string - */ - public function getHostname() - { - return $this->readOneof(5); - } - - public function hasHostname() - { - return $this->hasOneof(5); - } - - /** - * A Hostname (FQDN, e.g. `example.com`) or a wildcard hostname expression - * (`*.example.com`) for a set of hostnames with common suffix. Used as - * Server Name Indication (SNI) for selecting a proper certificate. - * - * Generated from protobuf field string hostname = 5; - * @param string $var - * @return $this - */ - public function setHostname($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A predefined matcher for particular cases, other than SNI selection. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry.Matcher matcher = 10; - * @return int - */ - public function getMatcher() - { - return $this->readOneof(10); - } - - public function hasMatcher() - { - return $this->hasOneof(10); - } - - /** - * A predefined matcher for particular cases, other than SNI selection. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry.Matcher matcher = 10; - * @param int $var - * @return $this - */ - public function setMatcher($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\CertificateMapEntry\Matcher::class); - $this->writeOneof(10, $var); - - return $this; - } - - /** - * A set of Certificates defines for the given `hostname`. There can be - * defined up to four certificates in each Certificate Map Entry. Each - * certificate must match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field repeated string certificates = 7 [(.google.api.resource_reference) = { - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertificates() - { - return $this->certificates; - } - - /** - * A set of Certificates defines for the given `hostname`. There can be - * defined up to four certificates in each Certificate Map Entry. Each - * certificate must match pattern `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field repeated string certificates = 7 [(.google.api.resource_reference) = { - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->certificates = $arr; - - return $this; - } - - /** - * Output only. A serving state of this Certificate Map Entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.ServingState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. A serving state of this Certificate Map Entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.ServingState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\CertificateManager\V1\ServingState::class); - $this->state = $var; - - return $this; - } - - /** - * @return string - */ - public function getMatch() - { - return $this->whichOneof("match"); - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry/Matcher.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry/Matcher.php deleted file mode 100644 index f837e74c7a8b..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry/Matcher.php +++ /dev/null @@ -1,59 +0,0 @@ -google.cloud.certificatemanager.v1.CertificateMapEntry.Matcher - */ -class Matcher -{ - /** - * A matcher has't been recognized. - * - * Generated from protobuf enum MATCHER_UNSPECIFIED = 0; - */ - const MATCHER_UNSPECIFIED = 0; - /** - * A primary certificate that is served when SNI wasn't specified in the - * request or SNI couldn't be found in the map. - * - * Generated from protobuf enum PRIMARY = 1; - */ - const PRIMARY = 1; - - private static $valueToName = [ - self::MATCHER_UNSPECIFIED => 'MATCHER_UNSPECIFIED', - self::PRIMARY => 'PRIMARY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Matcher::class, \Google\Cloud\CertificateManager\V1\CertificateMapEntry_Matcher::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry_Matcher.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry_Matcher.php deleted file mode 100644 index 5cae70eaefe7..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CertificateMapEntry_Matcher.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.certificatemanager.v1.CreateCertificateIssuanceConfigRequest - */ -class CreateCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A user-provided name of the certificate config. - * - * Generated from protobuf field string certificate_issuance_config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_issuance_config_id = ''; - /** - * Required. A definition of the certificate issuance config to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_config = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_issuance_config = null; - - /** - * @param string $parent Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $certificateIssuanceConfig Required. A definition of the certificate issuance config to create. - * @param string $certificateIssuanceConfigId Required. A user-provided name of the certificate config. - * - * @return \Google\Cloud\CertificateManager\V1\CreateCertificateIssuanceConfigRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $certificateIssuanceConfig, string $certificateIssuanceConfigId): self - { - return (new self()) - ->setParent($parent) - ->setCertificateIssuanceConfig($certificateIssuanceConfig) - ->setCertificateIssuanceConfigId($certificateIssuanceConfigId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. - * @type string $certificate_issuance_config_id - * Required. A user-provided name of the certificate config. - * @type \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $certificate_issuance_config - * Required. A definition of the certificate issuance config to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. A user-provided name of the certificate config. - * - * Generated from protobuf field string certificate_issuance_config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateIssuanceConfigId() - { - return $this->certificate_issuance_config_id; - } - - /** - * Required. A user-provided name of the certificate config. - * - * Generated from protobuf field string certificate_issuance_config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateIssuanceConfigId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_issuance_config_id = $var; - - return $this; - } - - /** - * Required. A definition of the certificate issuance config to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig|null - */ - public function getCertificateIssuanceConfig() - { - return $this->certificate_issuance_config; - } - - public function hasCertificateIssuanceConfig() - { - return isset($this->certificate_issuance_config); - } - - public function clearCertificateIssuanceConfig() - { - unset($this->certificate_issuance_config); - } - - /** - * Required. A definition of the certificate issuance config to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig $var - * @return $this - */ - public function setCertificateIssuanceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig::class); - $this->certificate_issuance_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapEntryRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapEntryRequest.php deleted file mode 100644 index 7c2df97476f0..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapEntryRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.certificatemanager.v1.CreateCertificateMapEntryRequest - */ -class CreateCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A user-provided name of the certificate map entry. - * - * Generated from protobuf field string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map_entry_id = ''; - /** - * Required. A definition of the certificate map entry to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map_entry = null; - - /** - * @param string $parent Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. Please see - * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. - * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create. - * @param string $certificateMapEntryId Required. A user-provided name of the certificate map entry. - * - * @return \Google\Cloud\CertificateManager\V1\CreateCertificateMapEntryRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry, string $certificateMapEntryId): self - { - return (new self()) - ->setParent($parent) - ->setCertificateMapEntry($certificateMapEntry) - ->setCertificateMapEntryId($certificateMapEntryId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. - * @type string $certificate_map_entry_id - * Required. A user-provided name of the certificate map entry. - * @type \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificate_map_entry - * Required. A definition of the certificate map entry to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. A user-provided name of the certificate map entry. - * - * Generated from protobuf field string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateMapEntryId() - { - return $this->certificate_map_entry_id; - } - - /** - * Required. A user-provided name of the certificate map entry. - * - * Generated from protobuf field string certificate_map_entry_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateMapEntryId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_map_entry_id = $var; - - return $this; - } - - /** - * Required. A definition of the certificate map entry to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateMapEntry|null - */ - public function getCertificateMapEntry() - { - return $this->certificate_map_entry; - } - - public function hasCertificateMapEntry() - { - return isset($this->certificate_map_entry); - } - - public function clearCertificateMapEntry() - { - unset($this->certificate_map_entry); - } - - /** - * Required. A definition of the certificate map entry to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $var - * @return $this - */ - public function setCertificateMapEntry($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateMapEntry::class); - $this->certificate_map_entry = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapRequest.php deleted file mode 100644 index 8722fd5327e7..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateMapRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.certificatemanager.v1.CreateCertificateMapRequest - */ -class CreateCertificateMapRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A user-provided name of the certificate map. - * - * Generated from protobuf field string certificate_map_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map_id = ''; - /** - * Required. A definition of the certificate map to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map = null; - - /** - * @param string $parent Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap Required. A definition of the certificate map to create. - * @param string $certificateMapId Required. A user-provided name of the certificate map. - * - * @return \Google\Cloud\CertificateManager\V1\CreateCertificateMapRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap, string $certificateMapId): self - { - return (new self()) - ->setParent($parent) - ->setCertificateMap($certificateMap) - ->setCertificateMapId($certificateMapId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. - * @type string $certificate_map_id - * Required. A user-provided name of the certificate map. - * @type \Google\Cloud\CertificateManager\V1\CertificateMap $certificate_map - * Required. A definition of the certificate map to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. A user-provided name of the certificate map. - * - * Generated from protobuf field string certificate_map_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateMapId() - { - return $this->certificate_map_id; - } - - /** - * Required. A user-provided name of the certificate map. - * - * Generated from protobuf field string certificate_map_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateMapId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_map_id = $var; - - return $this; - } - - /** - * Required. A definition of the certificate map to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateMap|null - */ - public function getCertificateMap() - { - return $this->certificate_map; - } - - public function hasCertificateMap() - { - return isset($this->certificate_map); - } - - public function clearCertificateMap() - { - unset($this->certificate_map); - } - - /** - * Required. A definition of the certificate map to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateMap $var - * @return $this - */ - public function setCertificateMap($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateMap::class); - $this->certificate_map = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateRequest.php deleted file mode 100644 index 0c98fd3b8a2b..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateCertificateRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.certificatemanager.v1.CreateCertificateRequest - */ -class CreateCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A user-provided name of the certificate. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_id = ''; - /** - * Required. A definition of the certificate to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate = null; - - /** - * @param string $parent Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\CertificateManager\V1\Certificate $certificate Required. A definition of the certificate to create. - * @param string $certificateId Required. A user-provided name of the certificate. - * - * @return \Google\Cloud\CertificateManager\V1\CreateCertificateRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\CertificateManager\V1\Certificate $certificate, string $certificateId): self - { - return (new self()) - ->setParent($parent) - ->setCertificate($certificate) - ->setCertificateId($certificateId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. - * @type string $certificate_id - * Required. A user-provided name of the certificate. - * @type \Google\Cloud\CertificateManager\V1\Certificate $certificate - * Required. A definition of the certificate to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. A user-provided name of the certificate. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateId() - { - return $this->certificate_id; - } - - /** - * Required. A user-provided name of the certificate. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_id = $var; - - return $this; - } - - /** - * Required. A definition of the certificate to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\Certificate|null - */ - public function getCertificate() - { - return $this->certificate; - } - - public function hasCertificate() - { - return isset($this->certificate); - } - - public function clearCertificate() - { - unset($this->certificate); - } - - /** - * Required. A definition of the certificate to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\Certificate $var - * @return $this - */ - public function setCertificate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\Certificate::class); - $this->certificate = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateDnsAuthorizationRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateDnsAuthorizationRequest.php deleted file mode 100644 index 4dea85970ea0..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/CreateDnsAuthorizationRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.certificatemanager.v1.CreateDnsAuthorizationRequest - */ -class CreateDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A user-provided name of the dns authorization. - * - * Generated from protobuf field string dns_authorization_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dns_authorization_id = ''; - /** - * Required. A definition of the dns authorization to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dns_authorization = null; - - /** - * @param string $parent Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to create. - * @param string $dnsAuthorizationId Required. A user-provided name of the dns authorization. - * - * @return \Google\Cloud\CertificateManager\V1\CreateDnsAuthorizationRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization, string $dnsAuthorizationId): self - { - return (new self()) - ->setParent($parent) - ->setDnsAuthorization($dnsAuthorization) - ->setDnsAuthorizationId($dnsAuthorizationId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. - * @type string $dns_authorization_id - * Required. A user-provided name of the dns authorization. - * @type \Google\Cloud\CertificateManager\V1\DnsAuthorization $dns_authorization - * Required. A definition of the dns authorization to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. A user-provided name of the dns authorization. - * - * Generated from protobuf field string dns_authorization_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDnsAuthorizationId() - { - return $this->dns_authorization_id; - } - - /** - * Required. A user-provided name of the dns authorization. - * - * Generated from protobuf field string dns_authorization_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDnsAuthorizationId($var) - { - GPBUtil::checkString($var, True); - $this->dns_authorization_id = $var; - - return $this; - } - - /** - * Required. A definition of the dns authorization to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\DnsAuthorization|null - */ - public function getDnsAuthorization() - { - return $this->dns_authorization; - } - - public function hasDnsAuthorization() - { - return isset($this->dns_authorization); - } - - public function clearDnsAuthorization() - { - unset($this->dns_authorization); - } - - /** - * Required. A definition of the dns authorization to create. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $var - * @return $this - */ - public function setDnsAuthorization($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\DnsAuthorization::class); - $this->dns_authorization = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateIssuanceConfigRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateIssuanceConfigRequest.php deleted file mode 100644 index b2c6e62341d8..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateIssuanceConfigRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.DeleteCertificateIssuanceConfigRequest - */ -class DeleteCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. Please see - * {@see CertificateManagerClient::certificateIssuanceConfigName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateIssuanceConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapEntryRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapEntryRequest.php deleted file mode 100644 index da88e1c8e7bf..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapEntryRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.DeleteCertificateMapEntryRequest - */ -class DeleteCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. Please see - * {@see CertificateManagerClient::certificateMapEntryName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateMapEntryRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapRequest.php deleted file mode 100644 index af8072648b58..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateMapRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.DeleteCertificateMapRequest - */ -class DeleteCertificateMapRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. Please see - * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateMapRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateRequest.php deleted file mode 100644 index a9a7e8cfeed0..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteCertificateRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.DeleteCertificateRequest - */ -class DeleteCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. Please see - * {@see CertificateManagerClient::certificateName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\DeleteCertificateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteDnsAuthorizationRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteDnsAuthorizationRequest.php deleted file mode 100644 index 278f4c74e2f0..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DeleteDnsAuthorizationRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.DeleteDnsAuthorizationRequest - */ -class DeleteDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. Please see - * {@see CertificateManagerClient::dnsAuthorizationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\DeleteDnsAuthorizationRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization.php deleted file mode 100644 index 3126f4fc9970..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization.php +++ /dev/null @@ -1,326 +0,0 @@ -google.cloud.certificatemanager.v1.DnsAuthorization - */ -class DnsAuthorization extends \Google\Protobuf\Internal\Message -{ - /** - * A user-defined name of the dns authorization. DnsAuthorization names must - * be unique globally and match pattern - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. The creation timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The last update timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Set of labels associated with a DnsAuthorization. - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - /** - * One or more paragraphs of text description of a DnsAuthorization. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * Required. Immutable. A domain that is being authorized. A DnsAuthorization - * resource covers a single domain and its wildcard, e.g. authorization for - * `example.com` can be used to issue certificates for `example.com` and - * `*.example.com`. - * - * Generated from protobuf field string domain = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $domain = ''; - /** - * Output only. DNS Resource Record that needs to be added to DNS - * configuration. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization.DnsResourceRecord dns_resource_record = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $dns_resource_record = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * A user-defined name of the dns authorization. DnsAuthorization names must - * be unique globally and match pattern - * `projects/*/locations/*/dnsAuthorizations/*`. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The creation timestamp of a DnsAuthorization. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The last update timestamp of a DnsAuthorization. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Set of labels associated with a DnsAuthorization. - * @type string $description - * One or more paragraphs of text description of a DnsAuthorization. - * @type string $domain - * Required. Immutable. A domain that is being authorized. A DnsAuthorization - * resource covers a single domain and its wildcard, e.g. authorization for - * `example.com` can be used to issue certificates for `example.com` and - * `*.example.com`. - * @type \Google\Cloud\CertificateManager\V1\DnsAuthorization\DnsResourceRecord $dns_resource_record - * Output only. DNS Resource Record that needs to be added to DNS - * configuration. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A user-defined name of the dns authorization. DnsAuthorization names must - * be unique globally and match pattern - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * A user-defined name of the dns authorization. DnsAuthorization names must - * be unique globally and match pattern - * `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The creation timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The creation timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The last update timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The last update timestamp of a DnsAuthorization. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Set of labels associated with a DnsAuthorization. - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Set of labels associated with a DnsAuthorization. - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * One or more paragraphs of text description of a DnsAuthorization. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * One or more paragraphs of text description of a DnsAuthorization. - * - * Generated from protobuf field string description = 5; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. Immutable. A domain that is being authorized. A DnsAuthorization - * resource covers a single domain and its wildcard, e.g. authorization for - * `example.com` can be used to issue certificates for `example.com` and - * `*.example.com`. - * - * Generated from protobuf field string domain = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getDomain() - { - return $this->domain; - } - - /** - * Required. Immutable. A domain that is being authorized. A DnsAuthorization - * resource covers a single domain and its wildcard, e.g. authorization for - * `example.com` can be used to issue certificates for `example.com` and - * `*.example.com`. - * - * Generated from protobuf field string domain = 6 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setDomain($var) - { - GPBUtil::checkString($var, True); - $this->domain = $var; - - return $this; - } - - /** - * Output only. DNS Resource Record that needs to be added to DNS - * configuration. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization.DnsResourceRecord dns_resource_record = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\CertificateManager\V1\DnsAuthorization\DnsResourceRecord|null - */ - public function getDnsResourceRecord() - { - return $this->dns_resource_record; - } - - public function hasDnsResourceRecord() - { - return isset($this->dns_resource_record); - } - - public function clearDnsResourceRecord() - { - unset($this->dns_resource_record); - } - - /** - * Output only. DNS Resource Record that needs to be added to DNS - * configuration. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization.DnsResourceRecord dns_resource_record = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization\DnsResourceRecord $var - * @return $this - */ - public function setDnsResourceRecord($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\DnsAuthorization\DnsResourceRecord::class); - $this->dns_resource_record = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization/DnsResourceRecord.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization/DnsResourceRecord.php deleted file mode 100644 index 285655ab9ae8..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization/DnsResourceRecord.php +++ /dev/null @@ -1,148 +0,0 @@ -google.cloud.certificatemanager.v1.DnsAuthorization.DnsResourceRecord - */ -class DnsResourceRecord extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Fully qualified name of the DNS Resource Record. - * e.g. `_acme-challenge.example.com` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Type of the DNS Resource Record. - * Currently always set to "CNAME". - * - * Generated from protobuf field string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $type = ''; - /** - * Output only. Data of the DNS Resource Record. - * - * Generated from protobuf field string data = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $data = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Fully qualified name of the DNS Resource Record. - * e.g. `_acme-challenge.example.com` - * @type string $type - * Output only. Type of the DNS Resource Record. - * Currently always set to "CNAME". - * @type string $data - * Output only. Data of the DNS Resource Record. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Fully qualified name of the DNS Resource Record. - * e.g. `_acme-challenge.example.com` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Fully qualified name of the DNS Resource Record. - * e.g. `_acme-challenge.example.com` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Type of the DNS Resource Record. - * Currently always set to "CNAME". - * - * Generated from protobuf field string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Output only. Type of the DNS Resource Record. - * Currently always set to "CNAME". - * - * Generated from protobuf field string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Output only. Data of the DNS Resource Record. - * - * Generated from protobuf field string data = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getData() - { - return $this->data; - } - - /** - * Output only. Data of the DNS Resource Record. - * - * Generated from protobuf field string data = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setData($var) - { - GPBUtil::checkString($var, True); - $this->data = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DnsResourceRecord::class, \Google\Cloud\CertificateManager\V1\DnsAuthorization_DnsResourceRecord::class); - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization_DnsResourceRecord.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization_DnsResourceRecord.php deleted file mode 100644 index 9335bd53aa7a..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/DnsAuthorization_DnsResourceRecord.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.certificatemanager.v1.GetCertificateIssuanceConfigRequest - */ -class GetCertificateIssuanceConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. Please see - * {@see CertificateManagerClient::certificateIssuanceConfigName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\GetCertificateIssuanceConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapEntryRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapEntryRequest.php deleted file mode 100644 index 8b44fefcef84..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapEntryRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.GetCertificateMapEntryRequest - */ -class GetCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. Please see - * {@see CertificateManagerClient::certificateMapEntryName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\GetCertificateMapEntryRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapRequest.php deleted file mode 100644 index e71586d22dad..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateMapRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.GetCertificateMapRequest - */ -class GetCertificateMapRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. Please see - * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\GetCertificateMapRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateRequest.php deleted file mode 100644 index f7653fe02230..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetCertificateRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.GetCertificateRequest - */ -class GetCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. Please see - * {@see CertificateManagerClient::certificateName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\GetCertificateRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetDnsAuthorizationRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetDnsAuthorizationRequest.php deleted file mode 100644 index 31910ab7b79c..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/GetDnsAuthorizationRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.certificatemanager.v1.GetDnsAuthorizationRequest - */ -class GetDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. Please see - * {@see CertificateManagerClient::dnsAuthorizationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\GetDnsAuthorizationRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsRequest.php deleted file mode 100644 index e518d6583792..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsRequest.php +++ /dev/null @@ -1,242 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateIssuanceConfigsRequest - */ -class ListCertificateIssuanceConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of certificate configs to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListCertificateIssuanceConfigsResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateIssuanceConfigs` call, and that the system should return - * the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter expression to restrict the Certificates Configs returned. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * A list of Certificate Config field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * @type int $page_size - * Maximum number of certificate configs to return per call. - * @type string $page_token - * The value returned by the last `ListCertificateIssuanceConfigsResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateIssuanceConfigs` call, and that the system should return - * the next page of data. - * @type string $filter - * Filter expression to restrict the Certificates Configs returned. - * @type string $order_by - * A list of Certificate Config field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of certificate configs to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of certificate configs to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListCertificateIssuanceConfigsResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateIssuanceConfigs` call, and that the system should return - * the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListCertificateIssuanceConfigsResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateIssuanceConfigs` call, and that the system should return - * the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filter expression to restrict the Certificates Configs returned. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter expression to restrict the Certificates Configs returned. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * A list of Certificate Config field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * A list of Certificate Config field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsResponse.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsResponse.php deleted file mode 100644 index 8dfe8101b161..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateIssuanceConfigsResponse.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateIssuanceConfigsResponse - */ -class ListCertificateIssuanceConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of certificate configs for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_configs = 1; - */ - private $certificate_issuance_configs; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig>|\Google\Protobuf\Internal\RepeatedField $certificate_issuance_configs - * A list of certificate configs for the parent resource. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateIssuanceConfig::initOnce(); - parent::__construct($data); - } - - /** - * A list of certificate configs for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertificateIssuanceConfigs() - { - return $this->certificate_issuance_configs; - } - - /** - * A list of certificate configs for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateIssuanceConfig certificate_issuance_configs = 1; - * @param array<\Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertificateIssuanceConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig::class); - $this->certificate_issuance_configs = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesRequest.php deleted file mode 100644 index 590b360adc8e..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesRequest.php +++ /dev/null @@ -1,259 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateMapEntriesRequest - */ -class ListCertificateMapEntriesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of certificate map entries to return. The service may return - * fewer than this value. - * If unspecified, at most 50 certificate map entries will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListCertificateMapEntriesResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateMapEntries` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter expression to restrict the returned Certificate Map Entries. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * A list of Certificate Map Entry field names used to specify - * the order of the returned results. The default sorting order is ascending. - * To specify descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. Please see - * {@see CertificateManagerClient::certificateMapName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. - * @type int $page_size - * Maximum number of certificate map entries to return. The service may return - * fewer than this value. - * If unspecified, at most 50 certificate map entries will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * The value returned by the last `ListCertificateMapEntriesResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateMapEntries` call, and that the system should return the - * next page of data. - * @type string $filter - * Filter expression to restrict the returned Certificate Map Entries. - * @type string $order_by - * A list of Certificate Map Entry field names used to specify - * the order of the returned results. The default sorting order is ascending. - * To specify descending order for a field, add a suffix " desc". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of certificate map entries to return. The service may return - * fewer than this value. - * If unspecified, at most 50 certificate map entries will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of certificate map entries to return. The service may return - * fewer than this value. - * If unspecified, at most 50 certificate map entries will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListCertificateMapEntriesResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateMapEntries` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListCertificateMapEntriesResponse`. - * Indicates that this is a continuation of a prior - * `ListCertificateMapEntries` call, and that the system should return the - * next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filter expression to restrict the returned Certificate Map Entries. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter expression to restrict the returned Certificate Map Entries. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * A list of Certificate Map Entry field names used to specify - * the order of the returned results. The default sorting order is ascending. - * To specify descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * A list of Certificate Map Entry field names used to specify - * the order of the returned results. The default sorting order is ascending. - * To specify descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesResponse.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesResponse.php deleted file mode 100644 index 35b8335bce6a..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapEntriesResponse.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateMapEntriesResponse - */ -class ListCertificateMapEntriesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of certificate map entries for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entries = 1; - */ - private $certificate_map_entries; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\CertificateManager\V1\CertificateMapEntry>|\Google\Protobuf\Internal\RepeatedField $certificate_map_entries - * A list of certificate map entries for the parent resource. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A list of certificate map entries for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entries = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertificateMapEntries() - { - return $this->certificate_map_entries; - } - - /** - * A list of certificate map entries for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entries = 1; - * @param array<\Google\Cloud\CertificateManager\V1\CertificateMapEntry>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertificateMapEntries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\CertificateMapEntry::class); - $this->certificate_map_entries = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsRequest.php deleted file mode 100644 index f78e15bc0335..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsRequest.php +++ /dev/null @@ -1,238 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateMapsRequest - */ -class ListCertificateMapsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of certificate maps to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListCertificateMapsResponse`. Indicates - * that this is a continuation of a prior `ListCertificateMaps` call, and that - * the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter expression to restrict the Certificates Maps returned. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * A list of Certificate Map field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\ListCertificateMapsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. - * @type int $page_size - * Maximum number of certificate maps to return per call. - * @type string $page_token - * The value returned by the last `ListCertificateMapsResponse`. Indicates - * that this is a continuation of a prior `ListCertificateMaps` call, and that - * the system should return the next page of data. - * @type string $filter - * Filter expression to restrict the Certificates Maps returned. - * @type string $order_by - * A list of Certificate Map field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of certificate maps to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of certificate maps to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListCertificateMapsResponse`. Indicates - * that this is a continuation of a prior `ListCertificateMaps` call, and that - * the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListCertificateMapsResponse`. Indicates - * that this is a continuation of a prior `ListCertificateMaps` call, and that - * the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filter expression to restrict the Certificates Maps returned. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter expression to restrict the Certificates Maps returned. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * A list of Certificate Map field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * A list of Certificate Map field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsResponse.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsResponse.php deleted file mode 100644 index 7d953e5e8fe3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificateMapsResponse.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificateMapsResponse - */ -class ListCertificateMapsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of certificate maps for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap certificate_maps = 1; - */ - private $certificate_maps; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\CertificateManager\V1\CertificateMap>|\Google\Protobuf\Internal\RepeatedField $certificate_maps - * A list of certificate maps for the parent resource. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A list of certificate maps for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap certificate_maps = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertificateMaps() - { - return $this->certificate_maps; - } - - /** - * A list of certificate maps for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.CertificateMap certificate_maps = 1; - * @param array<\Google\Cloud\CertificateManager\V1\CertificateMap>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertificateMaps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\CertificateMap::class); - $this->certificate_maps = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesRequest.php deleted file mode 100644 index a7c59544916f..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesRequest.php +++ /dev/null @@ -1,238 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificatesRequest - */ -class ListCertificatesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of certificates to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListCertificatesResponse`. Indicates that - * this is a continuation of a prior `ListCertificates` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter expression to restrict the Certificates returned. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * A list of Certificate field names used to specify the order of the returned - * results. The default sorting order is ascending. To specify descending - * order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\ListCertificatesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * @type int $page_size - * Maximum number of certificates to return per call. - * @type string $page_token - * The value returned by the last `ListCertificatesResponse`. Indicates that - * this is a continuation of a prior `ListCertificates` call, and that the - * system should return the next page of data. - * @type string $filter - * Filter expression to restrict the Certificates returned. - * @type string $order_by - * A list of Certificate field names used to specify the order of the returned - * results. The default sorting order is ascending. To specify descending - * order for a field, add a suffix " desc". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of certificates to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of certificates to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListCertificatesResponse`. Indicates that - * this is a continuation of a prior `ListCertificates` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListCertificatesResponse`. Indicates that - * this is a continuation of a prior `ListCertificates` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filter expression to restrict the Certificates returned. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter expression to restrict the Certificates returned. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * A list of Certificate field names used to specify the order of the returned - * results. The default sorting order is ascending. To specify descending - * order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * A list of Certificate field names used to specify the order of the returned - * results. The default sorting order is ascending. To specify descending - * order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesResponse.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesResponse.php deleted file mode 100644 index c3a2b6c79ee3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListCertificatesResponse.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.certificatemanager.v1.ListCertificatesResponse - */ -class ListCertificatesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of certificates for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate certificates = 1; - */ - private $certificates; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\CertificateManager\V1\Certificate>|\Google\Protobuf\Internal\RepeatedField $certificates - * A list of certificates for the parent resource. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * A list of locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A list of certificates for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate certificates = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertificates() - { - return $this->certificates; - } - - /** - * A list of certificates for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.Certificate certificates = 1; - * @param array<\Google\Cloud\CertificateManager\V1\Certificate>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\Certificate::class); - $this->certificates = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsRequest.php deleted file mode 100644 index 12b8b7e996f6..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsRequest.php +++ /dev/null @@ -1,238 +0,0 @@ -google.cloud.certificatemanager.v1.ListDnsAuthorizationsRequest - */ -class ListDnsAuthorizationsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Maximum number of dns authorizations to return per call. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last `ListDnsAuthorizationsResponse`. Indicates - * that this is a continuation of a prior `ListDnsAuthorizations` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter expression to restrict the Dns Authorizations returned. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * A list of Dns Authorization field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. Please see - * {@see CertificateManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. - * @type int $page_size - * Maximum number of dns authorizations to return per call. - * @type string $page_token - * The value returned by the last `ListDnsAuthorizationsResponse`. Indicates - * that this is a continuation of a prior `ListDnsAuthorizations` call, and - * that the system should return the next page of data. - * @type string $filter - * Filter expression to restrict the Dns Authorizations returned. - * @type string $order_by - * A list of Dns Authorization field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Maximum number of dns authorizations to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Maximum number of dns authorizations to return per call. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last `ListDnsAuthorizationsResponse`. Indicates - * that this is a continuation of a prior `ListDnsAuthorizations` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListDnsAuthorizationsResponse`. Indicates - * that this is a continuation of a prior `ListDnsAuthorizations` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Filter expression to restrict the Dns Authorizations returned. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter expression to restrict the Dns Authorizations returned. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * A list of Dns Authorization field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * A list of Dns Authorization field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsResponse.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsResponse.php deleted file mode 100644 index ebe8652bff26..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ListDnsAuthorizationsResponse.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.certificatemanager.v1.ListDnsAuthorizationsResponse - */ -class ListDnsAuthorizationsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of dns authorizations for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorizations = 1; - */ - private $dns_authorizations; - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\CertificateManager\V1\DnsAuthorization>|\Google\Protobuf\Internal\RepeatedField $dns_authorizations - * A list of dns authorizations for the parent resource. - * @type string $next_page_token - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * A list of dns authorizations for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorizations = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDnsAuthorizations() - { - return $this->dns_authorizations; - } - - /** - * A list of dns authorizations for the parent resource. - * - * Generated from protobuf field repeated .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorizations = 1; - * @param array<\Google\Cloud\CertificateManager\V1\DnsAuthorization>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDnsAuthorizations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\CertificateManager\V1\DnsAuthorization::class); - $this->dns_authorizations = $arr; - - return $this; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If there might be more results than those appearing in this response, then - * `next_page_token` is included. To get the next set of results, call this - * method again using the value of `next_page_token` as `page_token`. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/OperationMetadata.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/OperationMetadata.php deleted file mode 100644 index 29a4297349a4..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/OperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.certificatemanager.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - */ - protected $create_time = null; - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - */ - protected $end_time = null; - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - */ - protected $target = ''; - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - */ - protected $verb = ''; - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - */ - protected $status_message = ''; - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - */ - protected $requested_cancellation = false; - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - */ - protected $api_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * The time the operation finished running. - * @type string $target - * Server-defined resource path for the target of the operation. - * @type string $verb - * Name of the verb executed by the operation. - * @type string $status_message - * Human-readable status of the operation, if any. - * @type bool $requested_cancellation - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * @type string $api_version - * API version used to start the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - * @return string - */ - public function getStatusMessage() - { - return $this->status_message; - } - - /** - * Human-readable status of the operation, if any. - * - * Generated from protobuf field string status_message = 5; - * @param string $var - * @return $this - */ - public function setStatusMessage($var) - { - GPBUtil::checkString($var, True); - $this->status_message = $var; - - return $this; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a - * [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to - * `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ServingState.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ServingState.php deleted file mode 100644 index 93a9c1284a76..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/ServingState.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.certificatemanager.v1.ServingState - */ -class ServingState -{ - /** - * The status is undefined. - * - * Generated from protobuf enum SERVING_STATE_UNSPECIFIED = 0; - */ - const SERVING_STATE_UNSPECIFIED = 0; - /** - * The configuration is serving. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * Update is in progress. Some frontends may serve this configuration. - * - * Generated from protobuf enum PENDING = 2; - */ - const PENDING = 2; - - private static $valueToName = [ - self::SERVING_STATE_UNSPECIFIED => 'SERVING_STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::PENDING => 'PENDING', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapEntryRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapEntryRequest.php deleted file mode 100644 index 913b850a98cd..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapEntryRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.certificatemanager.v1.UpdateCertificateMapEntryRequest - */ -class UpdateCertificateMapEntryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A definition of the certificate map entry to create map entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map_entry = null; - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create map entry. - * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateMapEntryRequest - * - * @experimental - */ - public static function build(\Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificateMapEntry, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificateMapEntry($certificateMapEntry) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\CertificateManager\V1\CertificateMapEntry $certificate_map_entry - * Required. A definition of the certificate map entry to create map entry. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A definition of the certificate map entry to create map entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateMapEntry|null - */ - public function getCertificateMapEntry() - { - return $this->certificate_map_entry; - } - - public function hasCertificateMapEntry() - { - return isset($this->certificate_map_entry); - } - - public function clearCertificateMapEntry() - { - unset($this->certificate_map_entry); - } - - /** - * Required. A definition of the certificate map entry to create map entry. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMapEntry certificate_map_entry = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateMapEntry $var - * @return $this - */ - public function setCertificateMapEntry($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateMapEntry::class); - $this->certificate_map_entry = $var; - - return $this; - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapRequest.php deleted file mode 100644 index 40f59853d238..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateMapRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.certificatemanager.v1.UpdateCertificateMapRequest - */ -class UpdateCertificateMapRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A definition of the certificate map to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_map = null; - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap Required. A definition of the certificate map to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateMapRequest - * - * @experimental - */ - public static function build(\Google\Cloud\CertificateManager\V1\CertificateMap $certificateMap, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificateMap($certificateMap) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\CertificateManager\V1\CertificateMap $certificate_map - * Required. A definition of the certificate map to update. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A definition of the certificate map to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\CertificateMap|null - */ - public function getCertificateMap() - { - return $this->certificate_map; - } - - public function hasCertificateMap() - { - return isset($this->certificate_map); - } - - public function clearCertificateMap() - { - unset($this->certificate_map); - } - - /** - * Required. A definition of the certificate map to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.CertificateMap certificate_map = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\CertificateMap $var - * @return $this - */ - public function setCertificateMap($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\CertificateMap::class); - $this->certificate_map = $var; - - return $this; - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateRequest.php deleted file mode 100644 index e83292dc17f9..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateCertificateRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.certificatemanager.v1.UpdateCertificateRequest - */ -class UpdateCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A definition of the certificate to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate = null; - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\CertificateManager\V1\Certificate $certificate Required. A definition of the certificate to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * @return \Google\Cloud\CertificateManager\V1\UpdateCertificateRequest - * - * @experimental - */ - public static function build(\Google\Cloud\CertificateManager\V1\Certificate $certificate, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificate($certificate) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\CertificateManager\V1\Certificate $certificate - * Required. A definition of the certificate to update. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A definition of the certificate to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\Certificate|null - */ - public function getCertificate() - { - return $this->certificate; - } - - public function hasCertificate() - { - return isset($this->certificate); - } - - public function clearCertificate() - { - unset($this->certificate); - } - - /** - * Required. A definition of the certificate to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\Certificate $var - * @return $this - */ - public function setCertificate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\Certificate::class); - $this->certificate = $var; - - return $this; - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateDnsAuthorizationRequest.php b/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateDnsAuthorizationRequest.php deleted file mode 100644 index 52ae22852837..000000000000 --- a/owl-bot-staging/CertificateManager/v1/proto/src/Google/Cloud/CertificateManager/V1/UpdateDnsAuthorizationRequest.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.certificatemanager.v1.UpdateDnsAuthorizationRequest - */ -class UpdateDnsAuthorizationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A definition of the dns authorization to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dns_authorization = null; - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to update. - * @param \Google\Protobuf\FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * @return \Google\Cloud\CertificateManager\V1\UpdateDnsAuthorizationRequest - * - * @experimental - */ - public static function build(\Google\Cloud\CertificateManager\V1\DnsAuthorization $dnsAuthorization, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDnsAuthorization($dnsAuthorization) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\CertificateManager\V1\DnsAuthorization $dns_authorization - * Required. A definition of the dns authorization to update. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Certificatemanager\V1\CertificateManager::initOnce(); - parent::__construct($data); - } - - /** - * Required. A definition of the dns authorization to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\CertificateManager\V1\DnsAuthorization|null - */ - public function getDnsAuthorization() - { - return $this->dns_authorization; - } - - public function hasDnsAuthorization() - { - return isset($this->dns_authorization); - } - - public function clearDnsAuthorization() - { - unset($this->dns_authorization); - } - - /** - * Required. A definition of the dns authorization to update. - * - * Generated from protobuf field .google.cloud.certificatemanager.v1.DnsAuthorization dns_authorization = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\CertificateManager\V1\DnsAuthorization $var - * @return $this - */ - public function setDnsAuthorization($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\CertificateManager\V1\DnsAuthorization::class); - $this->dns_authorization = $var; - - return $this; - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate.php deleted file mode 100644 index 6de211c3b169..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate.php +++ /dev/null @@ -1,89 +0,0 @@ -setParent($formattedParent) - ->setCertificateId($certificateId) - ->setCertificate($certificate); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificate($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Certificate $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $certificateId = '[CERTIFICATE_ID]'; - - create_certificate_sample($formattedParent, $certificateId); -} -// [END certificatemanager_v1_generated_CertificateManager_CreateCertificate_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php deleted file mode 100644 index 82088a6702a3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_issuance_config.php +++ /dev/null @@ -1,113 +0,0 @@ -setCertificateAuthorityConfig($certificateIssuanceConfigCertificateAuthorityConfig) - ->setLifetime($certificateIssuanceConfigLifetime) - ->setRotationWindowPercentage($certificateIssuanceConfigRotationWindowPercentage) - ->setKeyAlgorithm($certificateIssuanceConfigKeyAlgorithm); - $request = (new CreateCertificateIssuanceConfigRequest()) - ->setParent($formattedParent) - ->setCertificateIssuanceConfigId($certificateIssuanceConfigId) - ->setCertificateIssuanceConfig($certificateIssuanceConfig); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateIssuanceConfig($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateIssuanceConfig $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $certificateIssuanceConfigId = '[CERTIFICATE_ISSUANCE_CONFIG_ID]'; - $certificateIssuanceConfigRotationWindowPercentage = 0; - $certificateIssuanceConfigKeyAlgorithm = KeyAlgorithm::KEY_ALGORITHM_UNSPECIFIED; - - create_certificate_issuance_config_sample( - $formattedParent, - $certificateIssuanceConfigId, - $certificateIssuanceConfigRotationWindowPercentage, - $certificateIssuanceConfigKeyAlgorithm - ); -} -// [END certificatemanager_v1_generated_CertificateManager_CreateCertificateIssuanceConfig_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map.php deleted file mode 100644 index 0e7cb5fa552f..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map.php +++ /dev/null @@ -1,89 +0,0 @@ -setParent($formattedParent) - ->setCertificateMapId($certificateMapId) - ->setCertificateMap($certificateMap); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateMap($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateMap $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $certificateMapId = '[CERTIFICATE_MAP_ID]'; - - create_certificate_map_sample($formattedParent, $certificateMapId); -} -// [END certificatemanager_v1_generated_CertificateManager_CreateCertificateMap_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map_entry.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map_entry.php deleted file mode 100644 index 31c19194db32..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_certificate_map_entry.php +++ /dev/null @@ -1,95 +0,0 @@ -setParent($formattedParent) - ->setCertificateMapEntryId($certificateMapEntryId) - ->setCertificateMapEntry($certificateMapEntry); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->createCertificateMapEntry($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateMapEntry $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 = CertificateManagerClient::certificateMapName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]' - ); - $certificateMapEntryId = '[CERTIFICATE_MAP_ENTRY_ID]'; - - create_certificate_map_entry_sample($formattedParent, $certificateMapEntryId); -} -// [END certificatemanager_v1_generated_CertificateManager_CreateCertificateMapEntry_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_dns_authorization.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_dns_authorization.php deleted file mode 100644 index 4994b4f6d3d4..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/create_dns_authorization.php +++ /dev/null @@ -1,98 +0,0 @@ -setDomain($dnsAuthorizationDomain); - $request = (new CreateDnsAuthorizationRequest()) - ->setParent($formattedParent) - ->setDnsAuthorizationId($dnsAuthorizationId) - ->setDnsAuthorization($dnsAuthorization); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->createDnsAuthorization($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var DnsAuthorization $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $dnsAuthorizationId = '[DNS_AUTHORIZATION_ID]'; - $dnsAuthorizationDomain = '[DOMAIN]'; - - create_dns_authorization_sample($formattedParent, $dnsAuthorizationId, $dnsAuthorizationDomain); -} -// [END certificatemanager_v1_generated_CertificateManager_CreateDnsAuthorization_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate.php deleted file mode 100644 index 1116141b7a59..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificate($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 = CertificateManagerClient::certificateName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE]' - ); - - delete_certificate_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_DeleteCertificate_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php deleted file mode 100644 index 104b65539d79..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_issuance_config.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateIssuanceConfig($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 = CertificateManagerClient::certificateIssuanceConfigName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_ISSUANCE_CONFIG]' - ); - - delete_certificate_issuance_config_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_DeleteCertificateIssuanceConfig_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map.php deleted file mode 100644 index 223fe2d16b05..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map.php +++ /dev/null @@ -1,87 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateMap($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 = CertificateManagerClient::certificateMapName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]' - ); - - delete_certificate_map_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_DeleteCertificateMap_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php deleted file mode 100644 index 4f44149ccc86..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_certificate_map_entry.php +++ /dev/null @@ -1,86 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteCertificateMapEntry($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 = CertificateManagerClient::certificateMapEntryName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]', - '[CERTIFICATE_MAP_ENTRY]' - ); - - delete_certificate_map_entry_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_DeleteCertificateMapEntry_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_dns_authorization.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_dns_authorization.php deleted file mode 100644 index edb806682b18..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/delete_dns_authorization.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->deleteDnsAuthorization($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 = CertificateManagerClient::dnsAuthorizationName( - '[PROJECT]', - '[LOCATION]', - '[DNS_AUTHORIZATION]' - ); - - delete_dns_authorization_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_DeleteDnsAuthorization_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate.php deleted file mode 100644 index c2a766043b77..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Certificate $response */ - $response = $certificateManagerClient->getCertificate($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 = CertificateManagerClient::certificateName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE]' - ); - - get_certificate_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_GetCertificate_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php deleted file mode 100644 index c3cf47ac6a44..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_issuance_config.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateIssuanceConfig $response */ - $response = $certificateManagerClient->getCertificateIssuanceConfig($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 = CertificateManagerClient::certificateIssuanceConfigName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_ISSUANCE_CONFIG]' - ); - - get_certificate_issuance_config_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_GetCertificateIssuanceConfig_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map.php deleted file mode 100644 index 85e4c91359bb..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateMap $response */ - $response = $certificateManagerClient->getCertificateMap($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 = CertificateManagerClient::certificateMapName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]' - ); - - get_certificate_map_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_GetCertificateMap_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map_entry.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map_entry.php deleted file mode 100644 index 62c566d8630c..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_certificate_map_entry.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateMapEntry $response */ - $response = $certificateManagerClient->getCertificateMapEntry($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 = CertificateManagerClient::certificateMapEntryName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]', - '[CERTIFICATE_MAP_ENTRY]' - ); - - get_certificate_map_entry_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_GetCertificateMapEntry_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_dns_authorization.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_dns_authorization.php deleted file mode 100644 index 058f076d2c0a..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_dns_authorization.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DnsAuthorization $response */ - $response = $certificateManagerClient->getDnsAuthorization($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 = CertificateManagerClient::dnsAuthorizationName( - '[PROJECT]', - '[LOCATION]', - '[DNS_AUTHORIZATION]' - ); - - get_dns_authorization_sample($formattedName); -} -// [END certificatemanager_v1_generated_CertificateManager_GetDnsAuthorization_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_location.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_location.php deleted file mode 100644 index bc117928803c..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END certificatemanager_v1_generated_CertificateManager_GetLocation_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php deleted file mode 100644 index 29a31022a58a..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_issuance_configs.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateIssuanceConfigs($request); - - /** @var CertificateIssuanceConfig $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_certificate_issuance_configs_sample($formattedParent); -} -// [END certificatemanager_v1_generated_CertificateManager_ListCertificateIssuanceConfigs_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_map_entries.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_map_entries.php deleted file mode 100644 index bf557aa5b293..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_map_entries.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateMapEntries($request); - - /** @var CertificateMapEntry $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 = CertificateManagerClient::certificateMapName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_MAP]' - ); - - list_certificate_map_entries_sample($formattedParent); -} -// [END certificatemanager_v1_generated_CertificateManager_ListCertificateMapEntries_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_maps.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_maps.php deleted file mode 100644 index 5de770224329..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificate_maps.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificateMaps($request); - - /** @var CertificateMap $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_certificate_maps_sample($formattedParent); -} -// [END certificatemanager_v1_generated_CertificateManager_ListCertificateMaps_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificates.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificates.php deleted file mode 100644 index a55477119769..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_certificates.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listCertificates($request); - - /** @var Certificate $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_certificates_sample($formattedParent); -} -// [END certificatemanager_v1_generated_CertificateManager_ListCertificates_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_dns_authorizations.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_dns_authorizations.php deleted file mode 100644 index cf6082b45fdf..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_dns_authorizations.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateManagerClient->listDnsAuthorizations($request); - - /** @var DnsAuthorization $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 = CertificateManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_dns_authorizations_sample($formattedParent); -} -// [END certificatemanager_v1_generated_CertificateManager_ListDnsAuthorizations_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_locations.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_locations.php deleted file mode 100644 index f1b91f10ce69..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END certificatemanager_v1_generated_CertificateManager_ListLocations_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate.php deleted file mode 100644 index e029de2ce742..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate.php +++ /dev/null @@ -1,74 +0,0 @@ -setCertificate($certificate) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificate($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Certificate $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 certificatemanager_v1_generated_CertificateManager_UpdateCertificate_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map.php deleted file mode 100644 index 980110a05f9e..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map.php +++ /dev/null @@ -1,74 +0,0 @@ -setCertificateMap($certificateMap) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificateMap($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateMap $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 certificatemanager_v1_generated_CertificateManager_UpdateCertificateMap_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map_entry.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map_entry.php deleted file mode 100644 index ad30df5671a3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_certificate_map_entry.php +++ /dev/null @@ -1,74 +0,0 @@ -setCertificateMapEntry($certificateMapEntry) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateCertificateMapEntry($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateMapEntry $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 certificatemanager_v1_generated_CertificateManager_UpdateCertificateMapEntry_sync] diff --git a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_dns_authorization.php b/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_dns_authorization.php deleted file mode 100644 index bcac14028bd2..000000000000 --- a/owl-bot-staging/CertificateManager/v1/samples/V1/CertificateManagerClient/update_dns_authorization.php +++ /dev/null @@ -1,90 +0,0 @@ -setDomain($dnsAuthorizationDomain); - $updateMask = new FieldMask(); - $request = (new UpdateDnsAuthorizationRequest()) - ->setDnsAuthorization($dnsAuthorization) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateManagerClient->updateDnsAuthorization($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var DnsAuthorization $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 -{ - $dnsAuthorizationDomain = '[DOMAIN]'; - - update_dns_authorization_sample($dnsAuthorizationDomain); -} -// [END certificatemanager_v1_generated_CertificateManager_UpdateDnsAuthorization_sync] diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/CertificateManagerClient.php b/owl-bot-staging/CertificateManager/v1/src/V1/CertificateManagerClient.php deleted file mode 100644 index 7c61f9c1d23b..000000000000 --- a/owl-bot-staging/CertificateManager/v1/src/V1/CertificateManagerClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $certificateId = 'certificate_id'; - * $certificate = new Certificate(); - * $operationResponse = $certificateManagerClient->createCertificate($formattedParent, $certificateId, $certificate); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createCertificate($formattedParent, $certificateId, $certificate); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createCertificate'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * 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. - */ -class CertificateManagerGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.certificatemanager.v1.CertificateManager'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'certificatemanager.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $caPoolNameTemplate; - - private static $certificateNameTemplate; - - private static $certificateIssuanceConfigNameTemplate; - - private static $certificateMapNameTemplate; - - private static $certificateMapEntryNameTemplate; - - private static $dnsAuthorizationNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/certificate_manager_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/certificate_manager_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/certificate_manager_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/certificate_manager_rest_client_config.php', - ], - ], - ]; - } - - private static function getCaPoolNameTemplate() - { - if (self::$caPoolNameTemplate == null) { - self::$caPoolNameTemplate = new PathTemplate('projects/{project}/locations/{location}/caPools/{ca_pool}'); - } - - return self::$caPoolNameTemplate; - } - - private static function getCertificateNameTemplate() - { - if (self::$certificateNameTemplate == null) { - self::$certificateNameTemplate = new PathTemplate('projects/{project}/locations/{location}/certificates/{certificate}'); - } - - return self::$certificateNameTemplate; - } - - private static function getCertificateIssuanceConfigNameTemplate() - { - if (self::$certificateIssuanceConfigNameTemplate == null) { - self::$certificateIssuanceConfigNameTemplate = new PathTemplate('projects/{project}/locations/{location}/certificateIssuanceConfigs/{certificate_issuance_config}'); - } - - return self::$certificateIssuanceConfigNameTemplate; - } - - private static function getCertificateMapNameTemplate() - { - if (self::$certificateMapNameTemplate == null) { - self::$certificateMapNameTemplate = new PathTemplate('projects/{project}/locations/{location}/certificateMaps/{certificate_map}'); - } - - return self::$certificateMapNameTemplate; - } - - private static function getCertificateMapEntryNameTemplate() - { - if (self::$certificateMapEntryNameTemplate == null) { - self::$certificateMapEntryNameTemplate = new PathTemplate('projects/{project}/locations/{location}/certificateMaps/{certificate_map}/certificateMapEntries/{certificate_map_entry}'); - } - - return self::$certificateMapEntryNameTemplate; - } - - private static function getDnsAuthorizationNameTemplate() - { - if (self::$dnsAuthorizationNameTemplate == null) { - self::$dnsAuthorizationNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dnsAuthorizations/{dns_authorization}'); - } - - return self::$dnsAuthorizationNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'caPool' => self::getCaPoolNameTemplate(), - 'certificate' => self::getCertificateNameTemplate(), - 'certificateIssuanceConfig' => self::getCertificateIssuanceConfigNameTemplate(), - 'certificateMap' => self::getCertificateMapNameTemplate(), - 'certificateMapEntry' => self::getCertificateMapEntryNameTemplate(), - 'dnsAuthorization' => self::getDnsAuthorizationNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a ca_pool - * resource. - * - * @param string $project - * @param string $location - * @param string $caPool - * - * @return string The formatted ca_pool resource. - */ - public static function caPoolName($project, $location, $caPool) - { - return self::getCaPoolNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'ca_pool' => $caPool, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a certificate - * resource. - * - * @param string $project - * @param string $location - * @param string $certificate - * - * @return string The formatted certificate resource. - */ - public static function certificateName($project, $location, $certificate) - { - return self::getCertificateNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'certificate' => $certificate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_issuance_config resource. - * - * @param string $project - * @param string $location - * @param string $certificateIssuanceConfig - * - * @return string The formatted certificate_issuance_config resource. - */ - public static function certificateIssuanceConfigName($project, $location, $certificateIssuanceConfig) - { - return self::getCertificateIssuanceConfigNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'certificate_issuance_config' => $certificateIssuanceConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_map resource. - * - * @param string $project - * @param string $location - * @param string $certificateMap - * - * @return string The formatted certificate_map resource. - */ - public static function certificateMapName($project, $location, $certificateMap) - { - return self::getCertificateMapNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'certificate_map' => $certificateMap, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_map_entry resource. - * - * @param string $project - * @param string $location - * @param string $certificateMap - * @param string $certificateMapEntry - * - * @return string The formatted certificate_map_entry resource. - */ - public static function certificateMapEntryName($project, $location, $certificateMap, $certificateMapEntry) - { - return self::getCertificateMapEntryNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'certificate_map' => $certificateMap, - 'certificate_map_entry' => $certificateMapEntry, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * dns_authorization resource. - * - * @param string $project - * @param string $location - * @param string $dnsAuthorization - * - * @return string The formatted dns_authorization resource. - */ - public static function dnsAuthorizationName($project, $location, $dnsAuthorization) - { - return self::getDnsAuthorizationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'dns_authorization' => $dnsAuthorization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - caPool: projects/{project}/locations/{location}/caPools/{ca_pool} - * - certificate: projects/{project}/locations/{location}/certificates/{certificate} - * - certificateIssuanceConfig: projects/{project}/locations/{location}/certificateIssuanceConfigs/{certificate_issuance_config} - * - certificateMap: projects/{project}/locations/{location}/certificateMaps/{certificate_map} - * - certificateMapEntry: projects/{project}/locations/{location}/certificateMaps/{certificate_map}/certificateMapEntries/{certificate_map_entry} - * - dnsAuthorization: projects/{project}/locations/{location}/dnsAuthorizations/{dns_authorization} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'certificatemanager.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new Certificate in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * $certificateId = 'certificate_id'; - * $certificate = new Certificate(); - * $operationResponse = $certificateManagerClient->createCertificate($formattedParent, $certificateId, $certificate); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createCertificate($formattedParent, $certificateId, $certificate); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createCertificate'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the certificate. Must be in the format - * `projects/*/locations/*`. - * @param string $certificateId Required. A user-provided name of the certificate. - * @param Certificate $certificate Required. A definition of the certificate to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createCertificate($parent, $certificateId, $certificate, array $optionalArgs = []) - { - $request = new CreateCertificateRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setCertificateId($certificateId); - $request->setCertificate($certificate); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateCertificate', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new CertificateIssuanceConfig in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * $certificateIssuanceConfigId = 'certificate_issuance_config_id'; - * $certificateIssuanceConfig = new CertificateIssuanceConfig(); - * $operationResponse = $certificateManagerClient->createCertificateIssuanceConfig($formattedParent, $certificateIssuanceConfigId, $certificateIssuanceConfig); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createCertificateIssuanceConfig($formattedParent, $certificateIssuanceConfigId, $certificateIssuanceConfig); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createCertificateIssuanceConfig'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the certificate issuance config. Must be - * in the format `projects/*/locations/*`. - * @param string $certificateIssuanceConfigId Required. A user-provided name of the certificate config. - * @param CertificateIssuanceConfig $certificateIssuanceConfig Required. A definition of the certificate issuance config to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createCertificateIssuanceConfig($parent, $certificateIssuanceConfigId, $certificateIssuanceConfig, array $optionalArgs = []) - { - $request = new CreateCertificateIssuanceConfigRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setCertificateIssuanceConfigId($certificateIssuanceConfigId); - $request->setCertificateIssuanceConfig($certificateIssuanceConfig); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateCertificateIssuanceConfig', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new CertificateMap in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * $certificateMapId = 'certificate_map_id'; - * $certificateMap = new CertificateMap(); - * $operationResponse = $certificateManagerClient->createCertificateMap($formattedParent, $certificateMapId, $certificateMap); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createCertificateMap($formattedParent, $certificateMapId, $certificateMap); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createCertificateMap'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the certificate map. Must be in the format - * `projects/*/locations/*`. - * @param string $certificateMapId Required. A user-provided name of the certificate map. - * @param CertificateMap $certificateMap Required. A definition of the certificate map to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createCertificateMap($parent, $certificateMapId, $certificateMap, array $optionalArgs = []) - { - $request = new CreateCertificateMapRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setCertificateMapId($certificateMapId); - $request->setCertificateMap($certificateMap); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateCertificateMap', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new CertificateMapEntry in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - * $certificateMapEntryId = 'certificate_map_entry_id'; - * $certificateMapEntry = new CertificateMapEntry(); - * $operationResponse = $certificateManagerClient->createCertificateMapEntry($formattedParent, $certificateMapEntryId, $certificateMapEntry); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createCertificateMapEntry($formattedParent, $certificateMapEntryId, $certificateMapEntry); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createCertificateMapEntry'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the certificate map entry. Must be in the - * format `projects/*/locations/*/certificateMaps/*`. - * @param string $certificateMapEntryId Required. A user-provided name of the certificate map entry. - * @param CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createCertificateMapEntry($parent, $certificateMapEntryId, $certificateMapEntry, array $optionalArgs = []) - { - $request = new CreateCertificateMapEntryRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setCertificateMapEntryId($certificateMapEntryId); - $request->setCertificateMapEntry($certificateMapEntry); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateCertificateMapEntry', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a new DnsAuthorization in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * $dnsAuthorizationId = 'dns_authorization_id'; - * $dnsAuthorization = new DnsAuthorization(); - * $operationResponse = $certificateManagerClient->createDnsAuthorization($formattedParent, $dnsAuthorizationId, $dnsAuthorization); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->createDnsAuthorization($formattedParent, $dnsAuthorizationId, $dnsAuthorization); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'createDnsAuthorization'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource of the dns authorization. Must be in the - * format `projects/*/locations/*`. - * @param string $dnsAuthorizationId Required. A user-provided name of the dns authorization. - * @param DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createDnsAuthorization($parent, $dnsAuthorizationId, $dnsAuthorization, array $optionalArgs = []) - { - $request = new CreateDnsAuthorizationRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setDnsAuthorizationId($dnsAuthorizationId); - $request->setDnsAuthorization($dnsAuthorization); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateDnsAuthorization', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single Certificate. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - * $operationResponse = $certificateManagerClient->deleteCertificate($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->deleteCertificate($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'deleteCertificate'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate to delete. Must be in the format - * `projects/*/locations/*/certificates/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteCertificate($name, array $optionalArgs = []) - { - $request = new DeleteCertificateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteCertificate', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single CertificateIssuanceConfig. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - * $operationResponse = $certificateManagerClient->deleteCertificateIssuanceConfig($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->deleteCertificateIssuanceConfig($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'deleteCertificateIssuanceConfig'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate issuance config to delete. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteCertificateIssuanceConfig($name, array $optionalArgs = []) - { - $request = new DeleteCertificateIssuanceConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteCertificateIssuanceConfig', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single CertificateMap. A Certificate Map can't be deleted - * if it contains Certificate Map Entries. Remove all the entries from - * the map before calling this method. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - * $operationResponse = $certificateManagerClient->deleteCertificateMap($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->deleteCertificateMap($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'deleteCertificateMap'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate map to delete. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteCertificateMap($name, array $optionalArgs = []) - { - $request = new DeleteCertificateMapRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteCertificateMap', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single CertificateMapEntry. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - * $operationResponse = $certificateManagerClient->deleteCertificateMapEntry($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->deleteCertificateMapEntry($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'deleteCertificateMapEntry'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate map entry to delete. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteCertificateMapEntry($name, array $optionalArgs = []) - { - $request = new DeleteCertificateMapEntryRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteCertificateMapEntry', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single DnsAuthorization. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - * $operationResponse = $certificateManagerClient->deleteDnsAuthorization($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->deleteDnsAuthorization($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'deleteDnsAuthorization'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the dns authorization to delete. Must be in the format - * `projects/*/locations/*/dnsAuthorizations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteDnsAuthorization($name, array $optionalArgs = []) - { - $request = new DeleteDnsAuthorizationRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteDnsAuthorization', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single Certificate. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - * $response = $certificateManagerClient->getCertificate($formattedName); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate to describe. Must be in the format - * `projects/*/locations/*/certificates/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\CertificateManager\V1\Certificate - * - * @throws ApiException if the remote call fails - */ - public function getCertificate($name, array $optionalArgs = []) - { - $request = new GetCertificateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetCertificate', Certificate::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single CertificateIssuanceConfig. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - * $response = $certificateManagerClient->getCertificateIssuanceConfig($formattedName); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate issuance config to describe. Must be in - * the format `projects/*/locations/*/certificateIssuanceConfigs/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig - * - * @throws ApiException if the remote call fails - */ - public function getCertificateIssuanceConfig($name, array $optionalArgs = []) - { - $request = new GetCertificateIssuanceConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetCertificateIssuanceConfig', CertificateIssuanceConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single CertificateMap. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - * $response = $certificateManagerClient->getCertificateMap($formattedName); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate map to describe. Must be in the format - * `projects/*/locations/*/certificateMaps/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\CertificateManager\V1\CertificateMap - * - * @throws ApiException if the remote call fails - */ - public function getCertificateMap($name, array $optionalArgs = []) - { - $request = new GetCertificateMapRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetCertificateMap', CertificateMap::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single CertificateMapEntry. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - * $response = $certificateManagerClient->getCertificateMapEntry($formattedName); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the certificate map entry to describe. Must be in the - * format `projects/*/locations/*/certificateMaps/*/certificateMapEntries/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\CertificateManager\V1\CertificateMapEntry - * - * @throws ApiException if the remote call fails - */ - public function getCertificateMapEntry($name, array $optionalArgs = []) - { - $request = new GetCertificateMapEntryRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetCertificateMapEntry', CertificateMapEntry::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets details of a single DnsAuthorization. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedName = $certificateManagerClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - * $response = $certificateManagerClient->getDnsAuthorization($formattedName); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $name Required. A name of the dns authorization to describe. Must be in the - * format `projects/*/locations/*/dnsAuthorizations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\CertificateManager\V1\DnsAuthorization - * - * @throws ApiException if the remote call fails - */ - public function getDnsAuthorization($name, array $optionalArgs = []) - { - $request = new GetDnsAuthorizationRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetDnsAuthorization', DnsAuthorization::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists CertificateIssuanceConfigs in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listCertificateIssuanceConfigs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listCertificateIssuanceConfigs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filter expression to restrict the Certificates Configs returned. - * @type string $orderBy - * A list of Certificate Config field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listCertificateIssuanceConfigs($parent, array $optionalArgs = []) - { - $request = new ListCertificateIssuanceConfigsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListCertificateIssuanceConfigs', $optionalArgs, ListCertificateIssuanceConfigsResponse::class, $request); - } - - /** - * Lists CertificateMapEntries in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listCertificateMapEntries($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listCertificateMapEntries($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The project, location and certificate map from which the - * certificate map entries should be listed, specified in the format - * `projects/*/locations/*/certificateMaps/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filter expression to restrict the returned Certificate Map Entries. - * @type string $orderBy - * A list of Certificate Map Entry field names used to specify - * the order of the returned results. The default sorting order is ascending. - * To specify descending order for a field, add a suffix " desc". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listCertificateMapEntries($parent, array $optionalArgs = []) - { - $request = new ListCertificateMapEntriesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListCertificateMapEntries', $optionalArgs, ListCertificateMapEntriesResponse::class, $request); - } - - /** - * Lists CertificateMaps in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listCertificateMaps($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listCertificateMaps($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the certificate maps should - * be listed, specified in the format `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filter expression to restrict the Certificates Maps returned. - * @type string $orderBy - * A list of Certificate Map field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listCertificateMaps($parent, array $optionalArgs = []) - { - $request = new ListCertificateMapsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListCertificateMaps', $optionalArgs, ListCertificateMapsResponse::class, $request); - } - - /** - * Lists Certificates in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listCertificates($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listCertificates($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the certificate should be - * listed, specified in the format `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filter expression to restrict the Certificates returned. - * @type string $orderBy - * A list of Certificate field names used to specify the order of the returned - * results. The default sorting order is ascending. To specify descending - * order for a field, add a suffix " desc". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listCertificates($parent, array $optionalArgs = []) - { - $request = new ListCertificatesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListCertificates', $optionalArgs, ListCertificatesResponse::class, $request); - } - - /** - * Lists DnsAuthorizations in a given project and location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $formattedParent = $certificateManagerClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listDnsAuthorizations($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listDnsAuthorizations($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location from which the dns authorizations should - * be listed, specified in the format `projects/*/locations/*`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * Filter expression to restrict the Dns Authorizations returned. - * @type string $orderBy - * A list of Dns Authorization field names used to specify the order of the - * returned results. The default sorting order is ascending. To specify - * descending order for a field, add a suffix " desc". - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listDnsAuthorizations($parent, array $optionalArgs = []) - { - $request = new ListDnsAuthorizationsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDnsAuthorizations', $optionalArgs, ListDnsAuthorizationsResponse::class, $request); - } - - /** - * Updates a Certificate. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $certificate = new Certificate(); - * $updateMask = new FieldMask(); - * $operationResponse = $certificateManagerClient->updateCertificate($certificate, $updateMask); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->updateCertificate($certificate, $updateMask); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'updateCertificate'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param Certificate $certificate Required. A definition of the certificate to update. - * @param FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateCertificate($certificate, $updateMask, array $optionalArgs = []) - { - $request = new UpdateCertificateRequest(); - $requestParamHeaders = []; - $request->setCertificate($certificate); - $request->setUpdateMask($updateMask); - $requestParamHeaders['certificate.name'] = $certificate->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateCertificate', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates a CertificateMap. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $certificateMap = new CertificateMap(); - * $updateMask = new FieldMask(); - * $operationResponse = $certificateManagerClient->updateCertificateMap($certificateMap, $updateMask); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->updateCertificateMap($certificateMap, $updateMask); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'updateCertificateMap'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param CertificateMap $certificateMap Required. A definition of the certificate map to update. - * @param FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateCertificateMap($certificateMap, $updateMask, array $optionalArgs = []) - { - $request = new UpdateCertificateMapRequest(); - $requestParamHeaders = []; - $request->setCertificateMap($certificateMap); - $request->setUpdateMask($updateMask); - $requestParamHeaders['certificate_map.name'] = $certificateMap->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateCertificateMap', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates a CertificateMapEntry. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $certificateMapEntry = new CertificateMapEntry(); - * $updateMask = new FieldMask(); - * $operationResponse = $certificateManagerClient->updateCertificateMapEntry($certificateMapEntry, $updateMask); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->updateCertificateMapEntry($certificateMapEntry, $updateMask); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'updateCertificateMapEntry'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param CertificateMapEntry $certificateMapEntry Required. A definition of the certificate map entry to create map entry. - * @param FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateCertificateMapEntry($certificateMapEntry, $updateMask, array $optionalArgs = []) - { - $request = new UpdateCertificateMapEntryRequest(); - $requestParamHeaders = []; - $request->setCertificateMapEntry($certificateMapEntry); - $request->setUpdateMask($updateMask); - $requestParamHeaders['certificate_map_entry.name'] = $certificateMapEntry->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateCertificateMapEntry', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates a DnsAuthorization. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $dnsAuthorization = new DnsAuthorization(); - * $updateMask = new FieldMask(); - * $operationResponse = $certificateManagerClient->updateDnsAuthorization($dnsAuthorization, $updateMask); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $certificateManagerClient->updateDnsAuthorization($dnsAuthorization, $updateMask); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $certificateManagerClient->resumeOperation($operationName, 'updateDnsAuthorization'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param DnsAuthorization $dnsAuthorization Required. A definition of the dns authorization to update. - * @param FieldMask $updateMask Required. The update mask applies to the resource. For the `FieldMask` - * definition, see - * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateDnsAuthorization($dnsAuthorization, $updateMask, array $optionalArgs = []) - { - $request = new UpdateDnsAuthorizationRequest(); - $requestParamHeaders = []; - $request->setDnsAuthorization($dnsAuthorization); - $request->setUpdateMask($updateMask); - $requestParamHeaders['dns_authorization.name'] = $dnsAuthorization->getName(); - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateDnsAuthorization', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * $response = $certificateManagerClient->getLocation(); - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $certificateManagerClient = new CertificateManagerClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $certificateManagerClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $certificateManagerClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $certificateManagerClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } -} diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/gapic_metadata.json b/owl-bot-staging/CertificateManager/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 54b2574944c7..000000000000 --- a/owl-bot-staging/CertificateManager/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,148 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.certificatemanager.v1", - "libraryPackage": "Google\\Cloud\\CertificateManager\\V1", - "services": { - "CertificateManager": { - "clients": { - "grpc": { - "libraryClient": "CertificateManagerGapicClient", - "rpcs": { - "CreateCertificate": { - "methods": [ - "createCertificate" - ] - }, - "CreateCertificateIssuanceConfig": { - "methods": [ - "createCertificateIssuanceConfig" - ] - }, - "CreateCertificateMap": { - "methods": [ - "createCertificateMap" - ] - }, - "CreateCertificateMapEntry": { - "methods": [ - "createCertificateMapEntry" - ] - }, - "CreateDnsAuthorization": { - "methods": [ - "createDnsAuthorization" - ] - }, - "DeleteCertificate": { - "methods": [ - "deleteCertificate" - ] - }, - "DeleteCertificateIssuanceConfig": { - "methods": [ - "deleteCertificateIssuanceConfig" - ] - }, - "DeleteCertificateMap": { - "methods": [ - "deleteCertificateMap" - ] - }, - "DeleteCertificateMapEntry": { - "methods": [ - "deleteCertificateMapEntry" - ] - }, - "DeleteDnsAuthorization": { - "methods": [ - "deleteDnsAuthorization" - ] - }, - "GetCertificate": { - "methods": [ - "getCertificate" - ] - }, - "GetCertificateIssuanceConfig": { - "methods": [ - "getCertificateIssuanceConfig" - ] - }, - "GetCertificateMap": { - "methods": [ - "getCertificateMap" - ] - }, - "GetCertificateMapEntry": { - "methods": [ - "getCertificateMapEntry" - ] - }, - "GetDnsAuthorization": { - "methods": [ - "getDnsAuthorization" - ] - }, - "ListCertificateIssuanceConfigs": { - "methods": [ - "listCertificateIssuanceConfigs" - ] - }, - "ListCertificateMapEntries": { - "methods": [ - "listCertificateMapEntries" - ] - }, - "ListCertificateMaps": { - "methods": [ - "listCertificateMaps" - ] - }, - "ListCertificates": { - "methods": [ - "listCertificates" - ] - }, - "ListDnsAuthorizations": { - "methods": [ - "listDnsAuthorizations" - ] - }, - "UpdateCertificate": { - "methods": [ - "updateCertificate" - ] - }, - "UpdateCertificateMap": { - "methods": [ - "updateCertificateMap" - ] - }, - "UpdateCertificateMapEntry": { - "methods": [ - "updateCertificateMapEntry" - ] - }, - "UpdateDnsAuthorization": { - "methods": [ - "updateDnsAuthorization" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_client_config.json b/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_client_config.json deleted file mode 100644 index d4df1100fd3d..000000000000 --- a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_client_config.json +++ /dev/null @@ -1,164 +0,0 @@ -{ - "interfaces": { - "google.cloud.certificatemanager.v1.CertificateManager": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificateIssuanceConfig": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificateMap": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificateMapEntry": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateDnsAuthorization": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificateIssuanceConfig": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificateMap": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificateMapEntry": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteDnsAuthorization": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificateIssuanceConfig": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificateMap": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificateMapEntry": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDnsAuthorization": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateIssuanceConfigs": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateMapEntries": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateMaps": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificates": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListDnsAuthorizations": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCertificateMap": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCertificateMapEntry": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDnsAuthorization": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - } - } - } - } -} diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_descriptor_config.php b/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_descriptor_config.php deleted file mode 100644 index ae4523289cd3..000000000000 --- a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_descriptor_config.php +++ /dev/null @@ -1,481 +0,0 @@ - [ - 'google.cloud.certificatemanager.v1.CertificateManager' => [ - 'CreateCertificate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\Certificate', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateIssuanceConfig' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateMap' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\CertificateMap', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateMapEntry' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\CertificateMapEntry', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDnsAuthorization' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\DnsAuthorization', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCertificate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateIssuanceConfig' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateMap' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateMapEntry' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDnsAuthorization' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCertificate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\Certificate', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate.name', - 'fieldAccessors' => [ - 'getCertificate', - 'getName', - ], - ], - ], - ], - 'UpdateCertificateMap' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\CertificateMap', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate_map.name', - 'fieldAccessors' => [ - 'getCertificateMap', - 'getName', - ], - ], - ], - ], - 'UpdateCertificateMapEntry' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\CertificateMapEntry', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate_map_entry.name', - 'fieldAccessors' => [ - 'getCertificateMapEntry', - 'getName', - ], - ], - ], - ], - 'UpdateDnsAuthorization' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\CertificateManager\V1\DnsAuthorization', - 'metadataReturnType' => '\Google\Cloud\CertificateManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'dns_authorization.name', - 'fieldAccessors' => [ - 'getDnsAuthorization', - 'getName', - ], - ], - ], - ], - 'GetCertificate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\Certificate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateIssuanceConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateIssuanceConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateMap' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateMap', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateMapEntry' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\CertificateMapEntry', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsAuthorization' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\DnsAuthorization', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListCertificateIssuanceConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateIssuanceConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateIssuanceConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateMapEntries' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateMapEntries', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateMapEntriesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateMaps' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateMaps', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificateMapsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificates' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificates', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\ListCertificatesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListDnsAuthorizations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDnsAuthorizations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\CertificateManager\V1\ListDnsAuthorizationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'templateMap' => [ - 'caPool' => 'projects/{project}/locations/{location}/caPools/{ca_pool}', - 'certificate' => 'projects/{project}/locations/{location}/certificates/{certificate}', - 'certificateIssuanceConfig' => 'projects/{project}/locations/{location}/certificateIssuanceConfigs/{certificate_issuance_config}', - 'certificateMap' => 'projects/{project}/locations/{location}/certificateMaps/{certificate_map}', - 'certificateMapEntry' => 'projects/{project}/locations/{location}/certificateMaps/{certificate_map}/certificateMapEntries/{certificate_map_entry}', - 'dnsAuthorization' => 'projects/{project}/locations/{location}/dnsAuthorizations/{dns_authorization}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_rest_client_config.php b/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_rest_client_config.php deleted file mode 100644 index a68024b9898c..000000000000 --- a/owl-bot-staging/CertificateManager/v1/src/V1/resources/certificate_manager_rest_client_config.php +++ /dev/null @@ -1,384 +0,0 @@ - [ - 'google.cloud.certificatemanager.v1.CertificateManager' => [ - 'CreateCertificate' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificates', - 'body' => 'certificate', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_id', - ], - ], - 'CreateCertificateIssuanceConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateIssuanceConfigs', - 'body' => 'certificate_issuance_config', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_issuance_config_id', - ], - ], - 'CreateCertificateMap' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateMaps', - 'body' => 'certificate_map', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_map_id', - ], - ], - 'CreateCertificateMapEntry' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/certificateMaps/*}/certificateMapEntries', - 'body' => 'certificate_map_entry', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_map_entry_id', - ], - ], - 'CreateDnsAuthorization' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dnsAuthorizations', - 'body' => 'dns_authorization', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'dns_authorization_id', - ], - ], - 'DeleteCertificate' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificates/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateIssuanceConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateIssuanceConfigs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateMap' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateMaps/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateMapEntry' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateMaps/*/certificateMapEntries/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteDnsAuthorization' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsAuthorizations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificate' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificates/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateIssuanceConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateIssuanceConfigs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateMap' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateMaps/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateMapEntry' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateMaps/*/certificateMapEntries/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsAuthorization' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsAuthorizations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListCertificateIssuanceConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateIssuanceConfigs', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateMapEntries' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/certificateMaps/*}/certificateMapEntries', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateMaps' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateMaps', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificates' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificates', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListDnsAuthorizations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/dnsAuthorizations', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateCertificate' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate.name=projects/*/locations/*/certificates/*}', - 'body' => 'certificate', - 'placeholders' => [ - 'certificate.name' => [ - 'getters' => [ - 'getCertificate', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificateMap' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate_map.name=projects/*/locations/*/certificateMaps/*}', - 'body' => 'certificate_map', - 'placeholders' => [ - 'certificate_map.name' => [ - 'getters' => [ - 'getCertificateMap', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificateMapEntry' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate_map_entry.name=projects/*/locations/*/certificateMaps/*/certificateMapEntries/*}', - 'body' => 'certificate_map_entry', - 'placeholders' => [ - 'certificate_map_entry.name' => [ - 'getters' => [ - 'getCertificateMapEntry', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateDnsAuthorization' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{dns_authorization.name=projects/*/locations/*/dnsAuthorizations/*}', - 'body' => 'dns_authorization', - 'placeholders' => [ - 'dns_authorization.name' => [ - 'getters' => [ - 'getDnsAuthorization', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/CertificateManager/v1/tests/Unit/V1/CertificateManagerClientTest.php b/owl-bot-staging/CertificateManager/v1/tests/Unit/V1/CertificateManagerClientTest.php deleted file mode 100644 index 9186e747cbba..000000000000 --- a/owl-bot-staging/CertificateManager/v1/tests/Unit/V1/CertificateManagerClientTest.php +++ /dev/null @@ -1,2627 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return CertificateManagerClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new CertificateManagerClient($options); - } - - /** @test */ - public function createCertificateTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPemCertificate($pemCertificate); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateId = 'certificateId1494430915'; - $certificate = new Certificate(); - $response = $gapicClient->createCertificate($formattedParent, $certificateId, $certificate); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateId(); - $this->assertProtobufEquals($certificateId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificate(); - $this->assertProtobufEquals($certificate, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateId = 'certificateId1494430915'; - $certificate = new Certificate(); - $response = $gapicClient->createCertificate($formattedParent, $certificateId, $certificate); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateIssuanceConfigTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateIssuanceConfigTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $rotationWindowPercentage = 873917384; - $expectedResponse = new CertificateIssuanceConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setRotationWindowPercentage($rotationWindowPercentage); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateIssuanceConfigTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateIssuanceConfigId = 'certificateIssuanceConfigId635650044'; - $certificateIssuanceConfig = new CertificateIssuanceConfig(); - $certificateIssuanceConfigCertificateAuthorityConfig = new CertificateAuthorityConfig(); - $certificateIssuanceConfig->setCertificateAuthorityConfig($certificateIssuanceConfigCertificateAuthorityConfig); - $certificateIssuanceConfigLifetime = new Duration(); - $certificateIssuanceConfig->setLifetime($certificateIssuanceConfigLifetime); - $certificateIssuanceConfigRotationWindowPercentage = 1410864292; - $certificateIssuanceConfig->setRotationWindowPercentage($certificateIssuanceConfigRotationWindowPercentage); - $certificateIssuanceConfigKeyAlgorithm = KeyAlgorithm::KEY_ALGORITHM_UNSPECIFIED; - $certificateIssuanceConfig->setKeyAlgorithm($certificateIssuanceConfigKeyAlgorithm); - $response = $gapicClient->createCertificateIssuanceConfig($formattedParent, $certificateIssuanceConfigId, $certificateIssuanceConfig); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateIssuanceConfig', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateIssuanceConfigId(); - $this->assertProtobufEquals($certificateIssuanceConfigId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateIssuanceConfig(); - $this->assertProtobufEquals($certificateIssuanceConfig, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateIssuanceConfigTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateIssuanceConfigExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateIssuanceConfigTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateIssuanceConfigId = 'certificateIssuanceConfigId635650044'; - $certificateIssuanceConfig = new CertificateIssuanceConfig(); - $certificateIssuanceConfigCertificateAuthorityConfig = new CertificateAuthorityConfig(); - $certificateIssuanceConfig->setCertificateAuthorityConfig($certificateIssuanceConfigCertificateAuthorityConfig); - $certificateIssuanceConfigLifetime = new Duration(); - $certificateIssuanceConfig->setLifetime($certificateIssuanceConfigLifetime); - $certificateIssuanceConfigRotationWindowPercentage = 1410864292; - $certificateIssuanceConfig->setRotationWindowPercentage($certificateIssuanceConfigRotationWindowPercentage); - $certificateIssuanceConfigKeyAlgorithm = KeyAlgorithm::KEY_ALGORITHM_UNSPECIFIED; - $certificateIssuanceConfig->setKeyAlgorithm($certificateIssuanceConfigKeyAlgorithm); - $response = $gapicClient->createCertificateIssuanceConfig($formattedParent, $certificateIssuanceConfigId, $certificateIssuanceConfig); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateIssuanceConfigTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateMapTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateMap(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateMapTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateMapId = 'certificateMapId-2047700346'; - $certificateMap = new CertificateMap(); - $response = $gapicClient->createCertificateMap($formattedParent, $certificateMapId, $certificateMap); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateMap', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateMapId(); - $this->assertProtobufEquals($certificateMapId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateMap(); - $this->assertProtobufEquals($certificateMap, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateMapTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateMapExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateMapId = 'certificateMapId-2047700346'; - $certificateMap = new CertificateMap(); - $response = $gapicClient->createCertificateMap($formattedParent, $certificateMapId, $certificateMap); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateMapTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateMapEntryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $hostname = 'hostname-299803597'; - $expectedResponse = new CertificateMapEntry(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setHostname($hostname); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateMapEntryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $certificateMapEntryId = 'certificateMapEntryId78300467'; - $certificateMapEntry = new CertificateMapEntry(); - $response = $gapicClient->createCertificateMapEntry($formattedParent, $certificateMapEntryId, $certificateMapEntry); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/CreateCertificateMapEntry', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateMapEntryId(); - $this->assertProtobufEquals($certificateMapEntryId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateMapEntry(); - $this->assertProtobufEquals($certificateMapEntry, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateMapEntryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createCertificateMapEntryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $certificateMapEntryId = 'certificateMapEntryId78300467'; - $certificateMapEntry = new CertificateMapEntry(); - $response = $gapicClient->createCertificateMapEntry($formattedParent, $certificateMapEntryId, $certificateMapEntry); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateMapEntryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createDnsAuthorizationTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $domain = 'domain-1326197564'; - $expectedResponse = new DnsAuthorization(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setDomain($domain); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createDnsAuthorizationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dnsAuthorizationId = 'dnsAuthorizationId1795311351'; - $dnsAuthorization = new DnsAuthorization(); - $dnsAuthorizationDomain = 'dnsAuthorizationDomain2013928116'; - $dnsAuthorization->setDomain($dnsAuthorizationDomain); - $response = $gapicClient->createDnsAuthorization($formattedParent, $dnsAuthorizationId, $dnsAuthorization); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/CreateDnsAuthorization', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getDnsAuthorizationId(); - $this->assertProtobufEquals($dnsAuthorizationId, $actualValue); - $actualValue = $actualApiRequestObject->getDnsAuthorization(); - $this->assertProtobufEquals($dnsAuthorization, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createDnsAuthorizationTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createDnsAuthorizationExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $dnsAuthorizationId = 'dnsAuthorizationId1795311351'; - $dnsAuthorization = new DnsAuthorization(); - $dnsAuthorizationDomain = 'dnsAuthorizationDomain2013928116'; - $dnsAuthorization->setDomain($dnsAuthorizationDomain); - $response = $gapicClient->createDnsAuthorization($formattedParent, $dnsAuthorizationId, $dnsAuthorization); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createDnsAuthorizationTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - $response = $gapicClient->deleteCertificate($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - $response = $gapicClient->deleteCertificate($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateIssuanceConfigTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateIssuanceConfigTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateIssuanceConfigTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - $response = $gapicClient->deleteCertificateIssuanceConfig($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateIssuanceConfig', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateIssuanceConfigTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateIssuanceConfigExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateIssuanceConfigTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - $response = $gapicClient->deleteCertificateIssuanceConfig($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateIssuanceConfigTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateMapTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateMapTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $response = $gapicClient->deleteCertificateMap($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateMap', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateMapTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateMapExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $response = $gapicClient->deleteCertificateMap($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateMapTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateMapEntryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateMapEntryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - $response = $gapicClient->deleteCertificateMapEntry($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/DeleteCertificateMapEntry', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateMapEntryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteCertificateMapEntryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - $response = $gapicClient->deleteCertificateMapEntry($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateMapEntryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteDnsAuthorizationTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteDnsAuthorizationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - $response = $gapicClient->deleteDnsAuthorization($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/DeleteDnsAuthorization', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteDnsAuthorizationTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteDnsAuthorizationExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - $response = $gapicClient->deleteDnsAuthorization($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteDnsAuthorizationTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getCertificateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPemCertificate($pemCertificate); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - $response = $gapicClient->getCertificate($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE]'); - try { - $gapicClient->getCertificate($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateIssuanceConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $rotationWindowPercentage = 873917384; - $expectedResponse = new CertificateIssuanceConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setRotationWindowPercentage($rotationWindowPercentage); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - $response = $gapicClient->getCertificateIssuanceConfig($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateIssuanceConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateIssuanceConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateIssuanceConfigName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_ISSUANCE_CONFIG]'); - try { - $gapicClient->getCertificateIssuanceConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateMapTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateMap(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $response = $gapicClient->getCertificateMap($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateMap', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateMapExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - try { - $gapicClient->getCertificateMap($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateMapEntryTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $hostname = 'hostname-299803597'; - $expectedResponse = new CertificateMapEntry(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setHostname($hostname); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - $response = $gapicClient->getCertificateMapEntry($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/GetCertificateMapEntry', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateMapEntryExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->certificateMapEntryName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]', '[CERTIFICATE_MAP_ENTRY]'); - try { - $gapicClient->getCertificateMapEntry($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDnsAuthorizationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $domain = 'domain-1326197564'; - $expectedResponse = new DnsAuthorization(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setDomain($domain); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - $response = $gapicClient->getDnsAuthorization($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/GetDnsAuthorization', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDnsAuthorizationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->dnsAuthorizationName('[PROJECT]', '[LOCATION]', '[DNS_AUTHORIZATION]'); - try { - $gapicClient->getDnsAuthorization($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateIssuanceConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateIssuanceConfigsElement = new CertificateIssuanceConfig(); - $certificateIssuanceConfigs = [ - $certificateIssuanceConfigsElement, - ]; - $expectedResponse = new ListCertificateIssuanceConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateIssuanceConfigs($certificateIssuanceConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listCertificateIssuanceConfigs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateIssuanceConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateIssuanceConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateIssuanceConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listCertificateIssuanceConfigs($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateMapEntriesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateMapEntriesElement = new CertificateMapEntry(); - $certificateMapEntries = [ - $certificateMapEntriesElement, - ]; - $expectedResponse = new ListCertificateMapEntriesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateMapEntries($certificateMapEntries); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - $response = $gapicClient->listCertificateMapEntries($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateMapEntries()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateMapEntries', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateMapEntriesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->certificateMapName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_MAP]'); - try { - $gapicClient->listCertificateMapEntries($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateMapsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateMapsElement = new CertificateMap(); - $certificateMaps = [ - $certificateMapsElement, - ]; - $expectedResponse = new ListCertificateMapsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateMaps($certificateMaps); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listCertificateMaps($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateMaps()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificateMaps', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateMapsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listCertificateMaps($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificatesElement = new Certificate(); - $certificates = [ - $certificatesElement, - ]; - $expectedResponse = new ListCertificatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificates($certificates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listCertificates($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/ListCertificates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificatesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listCertificates($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDnsAuthorizationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dnsAuthorizationsElement = new DnsAuthorization(); - $dnsAuthorizations = [ - $dnsAuthorizationsElement, - ]; - $expectedResponse = new ListDnsAuthorizationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDnsAuthorizations($dnsAuthorizations); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listDnsAuthorizations($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDnsAuthorizations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/ListDnsAuthorizations', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDnsAuthorizationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listDnsAuthorizations($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateCertificateTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPemCertificate($pemCertificate); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificate = new Certificate(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificate($certificate, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificate(); - $this->assertProtobufEquals($certificate, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateCertificateExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $certificate = new Certificate(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificate($certificate, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateCertificateMapTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateMap(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateMapTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificateMap = new CertificateMap(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificateMap($certificateMap, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificateMap', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificateMap(); - $this->assertProtobufEquals($certificateMap, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateMapTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateCertificateMapExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateMapTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $certificateMap = new CertificateMap(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificateMap($certificateMap, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateMapTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateCertificateMapEntryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $hostname = 'hostname-299803597'; - $expectedResponse = new CertificateMapEntry(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setHostname($hostname); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateMapEntryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificateMapEntry = new CertificateMapEntry(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificateMapEntry($certificateMapEntry, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/UpdateCertificateMapEntry', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificateMapEntry(); - $this->assertProtobufEquals($certificateMapEntry, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateMapEntryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateCertificateMapEntryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateCertificateMapEntryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $certificateMapEntry = new CertificateMapEntry(); - $updateMask = new FieldMask(); - $response = $gapicClient->updateCertificateMapEntry($certificateMapEntry, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateMapEntryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateDnsAuthorizationTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $domain = 'domain-1326197564'; - $expectedResponse = new DnsAuthorization(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setDomain($domain); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateDnsAuthorizationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $dnsAuthorization = new DnsAuthorization(); - $dnsAuthorizationDomain = 'dnsAuthorizationDomain2013928116'; - $dnsAuthorization->setDomain($dnsAuthorizationDomain); - $updateMask = new FieldMask(); - $response = $gapicClient->updateDnsAuthorization($dnsAuthorization, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.certificatemanager.v1.CertificateManager/UpdateDnsAuthorization', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getDnsAuthorization(); - $this->assertProtobufEquals($dnsAuthorization, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateDnsAuthorizationTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateDnsAuthorizationExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateDnsAuthorizationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $dnsAuthorization = new DnsAuthorization(); - $dnsAuthorizationDomain = 'dnsAuthorizationDomain2013928116'; - $dnsAuthorization->setDomain($dnsAuthorizationDomain); - $updateMask = new FieldMask(); - $response = $gapicClient->updateDnsAuthorization($dnsAuthorization, $updateMask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateDnsAuthorizationTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/GPBMetadata/Google/Cloud/Confidentialcomputing/V1/Service.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/GPBMetadata/Google/Cloud/Confidentialcomputing/V1/Service.php deleted file mode 100644 index 6fd76f93ea6f..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/GPBMetadata/Google/Cloud/Confidentialcomputing/V1/Service.php +++ /dev/null @@ -1,71 +0,0 @@ -internalAddGeneratedFile( - ' -Œ -3google/cloud/confidentialcomputing/v1/service.proto%google.cloud.confidentialcomputing.v1google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.protogoogle/protobuf/timestamp.proto"¥ - Challenge -name ( BàA4 - create_time ( 2.google.protobuf.TimestampBàA4 - expire_time ( 2.google.protobuf.TimestampBàA -used (BàA - tpm_nonce ( BàA:nêAk -.confidentialcomputing.googleapis.com/Challenge9projects/{project}/locations/{location}/challenges/{uuid}" -CreateChallengeRequest9 -parent ( B)àAúA# -!locations.googleapis.com/LocationH - challenge ( 20.google.cloud.confidentialcomputing.v1.ChallengeBàA" -VerifyAttestationRequestI - challenge ( B6àAúA0 -.confidentialcomputing.googleapis.com/ChallengeS -gcp_credentials ( 25.google.cloud.confidentialcomputing.v1.GcpCredentialsBàAS -tpm_attestation ( 25.google.cloud.confidentialcomputing.v1.TpmAttestationBàA"; -VerifyAttestationResponse -oidc_claims_token ( BàA"3 -GcpCredentials! -service_account_id_tokens ( " -TpmAttestationK -quotes ( 2;.google.cloud.confidentialcomputing.v1.TpmAttestation.Quote - tcg_event_log (  -canonical_event_log (  -ak_cert (  - -cert_chain ( Ö -Quote - hash_algo (^ - -pcr_values ( 2J.google.cloud.confidentialcomputing.v1.TpmAttestation.Quote.PcrValuesEntry - raw_quote (  - raw_signature ( 0 -PcrValuesEntry -key ( -value ( :82· -ConfidentialComputingØ -CreateChallenge=.google.cloud.confidentialcomputing.v1.CreateChallengeRequest0.google.cloud.confidentialcomputing.v1.Challenge"T‚Óä“;"./v1/{parent=projects/*/locations/*}/challenges: challengeÚAparent,challengeè -VerifyAttestation?.google.cloud.confidentialcomputing.v1.VerifyAttestationRequest@.google.cloud.confidentialcomputing.v1.VerifyAttestationResponse"P‚Óä“J"E/v1/{challenge=projects/*/locations/*/challenges/*}:verifyAttestation:*XÊA$confidentialcomputing.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformB— -)com.google.cloud.confidentialcomputing.v1B ServiceProtoPZ_cloud.google.com/go/confidentialcomputing/apiv1/confidentialcomputingpb;confidentialcomputingpbª%Google.Cloud.ConfidentialComputing.V1Ê%Google\\Cloud\\ConfidentialComputing\\V1ê(Google::Cloud::ConfidentialComputing::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/Challenge.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/Challenge.php deleted file mode 100644 index d2ecc004fae0..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/Challenge.php +++ /dev/null @@ -1,231 +0,0 @@ -google.cloud.confidentialcomputing.v1.Challenge - */ -class Challenge extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name for this Challenge in the format - * `projects/*/locations/*/challenges/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. The time at which this Challenge was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time at which this Challenge will no longer be usable. It - * is also the expiration time for any tokens generated from this Challenge. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Output only. Indicates if this challenge has been used to generate a token. - * - * Generated from protobuf field bool used = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $used = false; - /** - * Output only. Identical to nonce, but as a string. - * - * Generated from protobuf field string tpm_nonce = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $tpm_nonce = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name for this Challenge in the format - * `projects/*/locations/*/challenges/*` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which this Challenge was created - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The time at which this Challenge will no longer be usable. It - * is also the expiration time for any tokens generated from this Challenge. - * @type bool $used - * Output only. Indicates if this challenge has been used to generate a token. - * @type string $tpm_nonce - * Output only. Identical to nonce, but as a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name for this Challenge in the format - * `projects/*/locations/*/challenges/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name for this Challenge in the format - * `projects/*/locations/*/challenges/*` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The time at which this Challenge was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which this Challenge was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time at which this Challenge will no longer be usable. It - * is also the expiration time for any tokens generated from this Challenge. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExpireTime() - { - return $this->expire_time; - } - - public function hasExpireTime() - { - return isset($this->expire_time); - } - - public function clearExpireTime() - { - unset($this->expire_time); - } - - /** - * Output only. The time at which this Challenge will no longer be usable. It - * is also the expiration time for any tokens generated from this Challenge. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExpireTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->expire_time = $var; - - return $this; - } - - /** - * Output only. Indicates if this challenge has been used to generate a token. - * - * Generated from protobuf field bool used = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getUsed() - { - return $this->used; - } - - /** - * Output only. Indicates if this challenge has been used to generate a token. - * - * Generated from protobuf field bool used = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setUsed($var) - { - GPBUtil::checkBool($var); - $this->used = $var; - - return $this; - } - - /** - * Output only. Identical to nonce, but as a string. - * - * Generated from protobuf field string tpm_nonce = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTpmNonce() - { - return $this->tpm_nonce; - } - - /** - * Output only. Identical to nonce, but as a string. - * - * Generated from protobuf field string tpm_nonce = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTpmNonce($var) - { - GPBUtil::checkString($var, True); - $this->tpm_nonce = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/ConfidentialComputingGrpcClient.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/ConfidentialComputingGrpcClient.php deleted file mode 100644 index 78617b405a43..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/ConfidentialComputingGrpcClient.php +++ /dev/null @@ -1,65 +0,0 @@ -_simpleRequest('/google.cloud.confidentialcomputing.v1.ConfidentialComputing/CreateChallenge', - $argument, - ['\Google\Cloud\ConfidentialComputing\V1\Challenge', 'decode'], - $metadata, $options); - } - - /** - * Verifies the provided attestation info, returning a signed OIDC token. - * @param \Google\Cloud\ConfidentialComputing\V1\VerifyAttestationRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function VerifyAttestation(\Google\Cloud\ConfidentialComputing\V1\VerifyAttestationRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.confidentialcomputing.v1.ConfidentialComputing/VerifyAttestation', - $argument, - ['\Google\Cloud\ConfidentialComputing\V1\VerifyAttestationResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/CreateChallengeRequest.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/CreateChallengeRequest.php deleted file mode 100644 index 384853512d20..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/CreateChallengeRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.confidentialcomputing.v1.CreateChallengeRequest - */ -class CreateChallengeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.Challenge challenge = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $challenge = null; - - /** - * @param string $parent Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. Please see - * {@see ConfidentialComputingClient::locationName()} for help formatting this field. - * @param \Google\Cloud\ConfidentialComputing\V1\Challenge $challenge Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * - * @return \Google\Cloud\ConfidentialComputing\V1\CreateChallengeRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\ConfidentialComputing\V1\Challenge $challenge): self - { - return (new self()) - ->setParent($parent) - ->setChallenge($challenge); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. - * @type \Google\Cloud\ConfidentialComputing\V1\Challenge $challenge - * Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.Challenge challenge = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ConfidentialComputing\V1\Challenge|null - */ - public function getChallenge() - { - return $this->challenge; - } - - public function hasChallenge() - { - return isset($this->challenge); - } - - public function clearChallenge() - { - unset($this->challenge); - } - - /** - * Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.Challenge challenge = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ConfidentialComputing\V1\Challenge $var - * @return $this - */ - public function setChallenge($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ConfidentialComputing\V1\Challenge::class); - $this->challenge = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/GcpCredentials.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/GcpCredentials.php deleted file mode 100644 index 20a115c11118..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/GcpCredentials.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.confidentialcomputing.v1.GcpCredentials - */ -class GcpCredentials extends \Google\Protobuf\Internal\Message -{ - /** - * Same as id_tokens, but as a string. - * - * Generated from protobuf field repeated string service_account_id_tokens = 2; - */ - private $service_account_id_tokens; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $service_account_id_tokens - * Same as id_tokens, but as a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Same as id_tokens, but as a string. - * - * Generated from protobuf field repeated string service_account_id_tokens = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getServiceAccountIdTokens() - { - return $this->service_account_id_tokens; - } - - /** - * Same as id_tokens, but as a string. - * - * Generated from protobuf field repeated string service_account_id_tokens = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setServiceAccountIdTokens($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->service_account_id_tokens = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation.php deleted file mode 100644 index 4aa3a65e7f5c..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation.php +++ /dev/null @@ -1,228 +0,0 @@ -google.cloud.confidentialcomputing.v1.TpmAttestation - */ -class TpmAttestation extends \Google\Protobuf\Internal\Message -{ - /** - * TPM2 PCR Quotes generated by calling TPM2_Quote on each PCR bank. - * - * Generated from protobuf field repeated .google.cloud.confidentialcomputing.v1.TpmAttestation.Quote quotes = 1; - */ - private $quotes; - /** - * The binary TCG Event Log containing events measured into the TPM by the - * platform firmware and operating system. Formatted as described in the - * "TCG PC Client Platform Firmware Profile Specification". - * - * Generated from protobuf field bytes tcg_event_log = 2; - */ - protected $tcg_event_log = ''; - /** - * An Event Log containing additional events measured into the TPM that are - * not already present in the tcg_event_log. Formatted as described in the - * "Canonical Event Log Format" TCG Specification. - * - * Generated from protobuf field bytes canonical_event_log = 3; - */ - protected $canonical_event_log = ''; - /** - * DER-encoded X.509 certificate of the Attestation Key (otherwise known as - * an AK or a TPM restricted signing key) used to generate the quotes. - * - * Generated from protobuf field bytes ak_cert = 4; - */ - protected $ak_cert = ''; - /** - * List of DER-encoded X.509 certificates which, together with the ak_cert, - * chain back to a trusted Root Certificate. - * - * Generated from protobuf field repeated bytes cert_chain = 5; - */ - private $cert_chain; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\ConfidentialComputing\V1\TpmAttestation\Quote>|\Google\Protobuf\Internal\RepeatedField $quotes - * TPM2 PCR Quotes generated by calling TPM2_Quote on each PCR bank. - * @type string $tcg_event_log - * The binary TCG Event Log containing events measured into the TPM by the - * platform firmware and operating system. Formatted as described in the - * "TCG PC Client Platform Firmware Profile Specification". - * @type string $canonical_event_log - * An Event Log containing additional events measured into the TPM that are - * not already present in the tcg_event_log. Formatted as described in the - * "Canonical Event Log Format" TCG Specification. - * @type string $ak_cert - * DER-encoded X.509 certificate of the Attestation Key (otherwise known as - * an AK or a TPM restricted signing key) used to generate the quotes. - * @type array|\Google\Protobuf\Internal\RepeatedField $cert_chain - * List of DER-encoded X.509 certificates which, together with the ak_cert, - * chain back to a trusted Root Certificate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * TPM2 PCR Quotes generated by calling TPM2_Quote on each PCR bank. - * - * Generated from protobuf field repeated .google.cloud.confidentialcomputing.v1.TpmAttestation.Quote quotes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getQuotes() - { - return $this->quotes; - } - - /** - * TPM2 PCR Quotes generated by calling TPM2_Quote on each PCR bank. - * - * Generated from protobuf field repeated .google.cloud.confidentialcomputing.v1.TpmAttestation.Quote quotes = 1; - * @param array<\Google\Cloud\ConfidentialComputing\V1\TpmAttestation\Quote>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setQuotes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ConfidentialComputing\V1\TpmAttestation\Quote::class); - $this->quotes = $arr; - - return $this; - } - - /** - * The binary TCG Event Log containing events measured into the TPM by the - * platform firmware and operating system. Formatted as described in the - * "TCG PC Client Platform Firmware Profile Specification". - * - * Generated from protobuf field bytes tcg_event_log = 2; - * @return string - */ - public function getTcgEventLog() - { - return $this->tcg_event_log; - } - - /** - * The binary TCG Event Log containing events measured into the TPM by the - * platform firmware and operating system. Formatted as described in the - * "TCG PC Client Platform Firmware Profile Specification". - * - * Generated from protobuf field bytes tcg_event_log = 2; - * @param string $var - * @return $this - */ - public function setTcgEventLog($var) - { - GPBUtil::checkString($var, False); - $this->tcg_event_log = $var; - - return $this; - } - - /** - * An Event Log containing additional events measured into the TPM that are - * not already present in the tcg_event_log. Formatted as described in the - * "Canonical Event Log Format" TCG Specification. - * - * Generated from protobuf field bytes canonical_event_log = 3; - * @return string - */ - public function getCanonicalEventLog() - { - return $this->canonical_event_log; - } - - /** - * An Event Log containing additional events measured into the TPM that are - * not already present in the tcg_event_log. Formatted as described in the - * "Canonical Event Log Format" TCG Specification. - * - * Generated from protobuf field bytes canonical_event_log = 3; - * @param string $var - * @return $this - */ - public function setCanonicalEventLog($var) - { - GPBUtil::checkString($var, False); - $this->canonical_event_log = $var; - - return $this; - } - - /** - * DER-encoded X.509 certificate of the Attestation Key (otherwise known as - * an AK or a TPM restricted signing key) used to generate the quotes. - * - * Generated from protobuf field bytes ak_cert = 4; - * @return string - */ - public function getAkCert() - { - return $this->ak_cert; - } - - /** - * DER-encoded X.509 certificate of the Attestation Key (otherwise known as - * an AK or a TPM restricted signing key) used to generate the quotes. - * - * Generated from protobuf field bytes ak_cert = 4; - * @param string $var - * @return $this - */ - public function setAkCert($var) - { - GPBUtil::checkString($var, False); - $this->ak_cert = $var; - - return $this; - } - - /** - * List of DER-encoded X.509 certificates which, together with the ak_cert, - * chain back to a trusted Root Certificate. - * - * Generated from protobuf field repeated bytes cert_chain = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCertChain() - { - return $this->cert_chain; - } - - /** - * List of DER-encoded X.509 certificates which, together with the ak_cert, - * chain back to a trusted Root Certificate. - * - * Generated from protobuf field repeated bytes cert_chain = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCertChain($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::BYTES); - $this->cert_chain = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation/Quote.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation/Quote.php deleted file mode 100644 index ebd0cf5c4a2d..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation/Quote.php +++ /dev/null @@ -1,173 +0,0 @@ -google.cloud.confidentialcomputing.v1.TpmAttestation.Quote - */ -class Quote extends \Google\Protobuf\Internal\Message -{ - /** - * The hash algorithm of the PCR bank being quoted, encoded as a TPM_ALG_ID - * - * Generated from protobuf field int32 hash_algo = 1; - */ - protected $hash_algo = 0; - /** - * Raw binary values of each PCRs being quoted. - * - * Generated from protobuf field map pcr_values = 2; - */ - private $pcr_values; - /** - * TPM2 quote, encoded as a TPMS_ATTEST - * - * Generated from protobuf field bytes raw_quote = 3; - */ - protected $raw_quote = ''; - /** - * TPM2 signature, encoded as a TPMT_SIGNATURE - * - * Generated from protobuf field bytes raw_signature = 4; - */ - protected $raw_signature = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $hash_algo - * The hash algorithm of the PCR bank being quoted, encoded as a TPM_ALG_ID - * @type array|\Google\Protobuf\Internal\MapField $pcr_values - * Raw binary values of each PCRs being quoted. - * @type string $raw_quote - * TPM2 quote, encoded as a TPMS_ATTEST - * @type string $raw_signature - * TPM2 signature, encoded as a TPMT_SIGNATURE - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The hash algorithm of the PCR bank being quoted, encoded as a TPM_ALG_ID - * - * Generated from protobuf field int32 hash_algo = 1; - * @return int - */ - public function getHashAlgo() - { - return $this->hash_algo; - } - - /** - * The hash algorithm of the PCR bank being quoted, encoded as a TPM_ALG_ID - * - * Generated from protobuf field int32 hash_algo = 1; - * @param int $var - * @return $this - */ - public function setHashAlgo($var) - { - GPBUtil::checkInt32($var); - $this->hash_algo = $var; - - return $this; - } - - /** - * Raw binary values of each PCRs being quoted. - * - * Generated from protobuf field map pcr_values = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getPcrValues() - { - return $this->pcr_values; - } - - /** - * Raw binary values of each PCRs being quoted. - * - * Generated from protobuf field map pcr_values = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setPcrValues($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::INT32, \Google\Protobuf\Internal\GPBType::BYTES); - $this->pcr_values = $arr; - - return $this; - } - - /** - * TPM2 quote, encoded as a TPMS_ATTEST - * - * Generated from protobuf field bytes raw_quote = 3; - * @return string - */ - public function getRawQuote() - { - return $this->raw_quote; - } - - /** - * TPM2 quote, encoded as a TPMS_ATTEST - * - * Generated from protobuf field bytes raw_quote = 3; - * @param string $var - * @return $this - */ - public function setRawQuote($var) - { - GPBUtil::checkString($var, False); - $this->raw_quote = $var; - - return $this; - } - - /** - * TPM2 signature, encoded as a TPMT_SIGNATURE - * - * Generated from protobuf field bytes raw_signature = 4; - * @return string - */ - public function getRawSignature() - { - return $this->raw_signature; - } - - /** - * TPM2 signature, encoded as a TPMT_SIGNATURE - * - * Generated from protobuf field bytes raw_signature = 4; - * @param string $var - * @return $this - */ - public function setRawSignature($var) - { - GPBUtil::checkString($var, False); - $this->raw_signature = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Quote::class, \Google\Cloud\ConfidentialComputing\V1\TpmAttestation_Quote::class); - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation_Quote.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation_Quote.php deleted file mode 100644 index 33653fdbd87c..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/TpmAttestation_Quote.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.confidentialcomputing.v1.VerifyAttestationRequest - */ -class VerifyAttestationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Challenge whose nonce was used to generate the - * attestation, in the format `projects/*/locations/*/challenges/*`. The - * provided Challenge will be consumed, and cannot be used again. - * - * Generated from protobuf field string challenge = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $challenge = ''; - /** - * Optional. Credentials used to populate the "emails" claim in the - * claims_token. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.GcpCredentials gcp_credentials = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $gcp_credentials = null; - /** - * Required. The TPM-specific data provided by the attesting platform, used to - * populate any of the claims regarding platform state. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.TpmAttestation tpm_attestation = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $tpm_attestation = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $challenge - * Required. The name of the Challenge whose nonce was used to generate the - * attestation, in the format `projects/*/locations/*/challenges/*`. The - * provided Challenge will be consumed, and cannot be used again. - * @type \Google\Cloud\ConfidentialComputing\V1\GcpCredentials $gcp_credentials - * Optional. Credentials used to populate the "emails" claim in the - * claims_token. - * @type \Google\Cloud\ConfidentialComputing\V1\TpmAttestation $tpm_attestation - * Required. The TPM-specific data provided by the attesting platform, used to - * populate any of the claims regarding platform state. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Challenge whose nonce was used to generate the - * attestation, in the format `projects/*/locations/*/challenges/*`. The - * provided Challenge will be consumed, and cannot be used again. - * - * Generated from protobuf field string challenge = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getChallenge() - { - return $this->challenge; - } - - /** - * Required. The name of the Challenge whose nonce was used to generate the - * attestation, in the format `projects/*/locations/*/challenges/*`. The - * provided Challenge will be consumed, and cannot be used again. - * - * Generated from protobuf field string challenge = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setChallenge($var) - { - GPBUtil::checkString($var, True); - $this->challenge = $var; - - return $this; - } - - /** - * Optional. Credentials used to populate the "emails" claim in the - * claims_token. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.GcpCredentials gcp_credentials = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\ConfidentialComputing\V1\GcpCredentials|null - */ - public function getGcpCredentials() - { - return $this->gcp_credentials; - } - - public function hasGcpCredentials() - { - return isset($this->gcp_credentials); - } - - public function clearGcpCredentials() - { - unset($this->gcp_credentials); - } - - /** - * Optional. Credentials used to populate the "emails" claim in the - * claims_token. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.GcpCredentials gcp_credentials = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\ConfidentialComputing\V1\GcpCredentials $var - * @return $this - */ - public function setGcpCredentials($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ConfidentialComputing\V1\GcpCredentials::class); - $this->gcp_credentials = $var; - - return $this; - } - - /** - * Required. The TPM-specific data provided by the attesting platform, used to - * populate any of the claims regarding platform state. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.TpmAttestation tpm_attestation = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ConfidentialComputing\V1\TpmAttestation|null - */ - public function getTpmAttestation() - { - return $this->tpm_attestation; - } - - public function hasTpmAttestation() - { - return isset($this->tpm_attestation); - } - - public function clearTpmAttestation() - { - unset($this->tpm_attestation); - } - - /** - * Required. The TPM-specific data provided by the attesting platform, used to - * populate any of the claims regarding platform state. - * - * Generated from protobuf field .google.cloud.confidentialcomputing.v1.TpmAttestation tpm_attestation = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ConfidentialComputing\V1\TpmAttestation $var - * @return $this - */ - public function setTpmAttestation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ConfidentialComputing\V1\TpmAttestation::class); - $this->tpm_attestation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/VerifyAttestationResponse.php b/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/VerifyAttestationResponse.php deleted file mode 100644 index 2a0e98365c56..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/proto/src/Google/Cloud/ConfidentialComputing/V1/VerifyAttestationResponse.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.confidentialcomputing.v1.VerifyAttestationResponse - */ -class VerifyAttestationResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Same as claims_token, but as a string. - * - * Generated from protobuf field string oidc_claims_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $oidc_claims_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $oidc_claims_token - * Output only. Same as claims_token, but as a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Confidentialcomputing\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Same as claims_token, but as a string. - * - * Generated from protobuf field string oidc_claims_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getOidcClaimsToken() - { - return $this->oidc_claims_token; - } - - /** - * Output only. Same as claims_token, but as a string. - * - * Generated from protobuf field string oidc_claims_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setOidcClaimsToken($var) - { - GPBUtil::checkString($var, True); - $this->oidc_claims_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/create_challenge.php b/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/create_challenge.php deleted file mode 100644 index 26af3b9671ba..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/create_challenge.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent) - ->setChallenge($challenge); - - // Call the API and handle any network failures. - try { - /** @var Challenge $response */ - $response = $confidentialComputingClient->createChallenge($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 = ConfidentialComputingClient::locationName('[PROJECT]', '[LOCATION]'); - - create_challenge_sample($formattedParent); -} -// [END confidentialcomputing_v1_generated_ConfidentialComputing_CreateChallenge_sync] diff --git a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/get_location.php b/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/get_location.php deleted file mode 100644 index 9e8b93c11b06..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/get_location.php +++ /dev/null @@ -1,57 +0,0 @@ -getLocation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END confidentialcomputing_v1_generated_ConfidentialComputing_GetLocation_sync] diff --git a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/list_locations.php b/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/list_locations.php deleted file mode 100644 index cdbfe21c4cf4..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/list_locations.php +++ /dev/null @@ -1,62 +0,0 @@ -listLocations($request); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END confidentialcomputing_v1_generated_ConfidentialComputing_ListLocations_sync] diff --git a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/verify_attestation.php b/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/verify_attestation.php deleted file mode 100644 index 87b339f829db..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/samples/V1/ConfidentialComputingClient/verify_attestation.php +++ /dev/null @@ -1,80 +0,0 @@ -setChallenge($formattedChallenge) - ->setTpmAttestation($tpmAttestation); - - // Call the API and handle any network failures. - try { - /** @var VerifyAttestationResponse $response */ - $response = $confidentialComputingClient->verifyAttestation($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 -{ - $formattedChallenge = ConfidentialComputingClient::challengeName( - '[PROJECT]', - '[LOCATION]', - '[UUID]' - ); - - verify_attestation_sample($formattedChallenge); -} -// [END confidentialcomputing_v1_generated_ConfidentialComputing_VerifyAttestation_sync] diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/ConfidentialComputingClient.php b/owl-bot-staging/ConfidentialComputing/v1/src/V1/ConfidentialComputingClient.php deleted file mode 100644 index ddbc2037fd4b..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/src/V1/ConfidentialComputingClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $challenge = new Challenge(); - * $response = $confidentialComputingClient->createChallenge($formattedParent, $challenge); - * } finally { - * $confidentialComputingClient->close(); - * } - * ``` - * - * 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. - */ -class ConfidentialComputingGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.confidentialcomputing.v1.ConfidentialComputing'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'confidentialcomputing.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $challengeNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/confidential_computing_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/confidential_computing_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/confidential_computing_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/confidential_computing_rest_client_config.php', - ], - ], - ]; - } - - private static function getChallengeNameTemplate() - { - if (self::$challengeNameTemplate == null) { - self::$challengeNameTemplate = new PathTemplate('projects/{project}/locations/{location}/challenges/{uuid}'); - } - - return self::$challengeNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'challenge' => self::getChallengeNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a challenge - * resource. - * - * @param string $project - * @param string $location - * @param string $uuid - * - * @return string The formatted challenge resource. - */ - public static function challengeName($project, $location, $uuid) - { - return self::getChallengeNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'uuid' => $uuid, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - challenge: projects/{project}/locations/{location}/challenges/{uuid} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'confidentialcomputing.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** - * Creates a new Challenge in a given project and location. - * - * Sample code: - * ``` - * $confidentialComputingClient = new ConfidentialComputingClient(); - * try { - * $formattedParent = $confidentialComputingClient->locationName('[PROJECT]', '[LOCATION]'); - * $challenge = new Challenge(); - * $response = $confidentialComputingClient->createChallenge($formattedParent, $challenge); - * } finally { - * $confidentialComputingClient->close(); - * } - * ``` - * - * @param string $parent Required. The resource name of the location where the Challenge will be - * used, in the format `projects/*/locations/*`. - * @param Challenge $challenge Required. The Challenge to be created. Currently this field can be empty as - * all the Challenge fields are set by the server. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ConfidentialComputing\V1\Challenge - * - * @throws ApiException if the remote call fails - */ - public function createChallenge($parent, $challenge, array $optionalArgs = []) - { - $request = new CreateChallengeRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setChallenge($challenge); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateChallenge', Challenge::class, $optionalArgs, $request)->wait(); - } - - /** - * Verifies the provided attestation info, returning a signed OIDC token. - * - * Sample code: - * ``` - * $confidentialComputingClient = new ConfidentialComputingClient(); - * try { - * $formattedChallenge = $confidentialComputingClient->challengeName('[PROJECT]', '[LOCATION]', '[UUID]'); - * $tpmAttestation = new TpmAttestation(); - * $response = $confidentialComputingClient->verifyAttestation($formattedChallenge, $tpmAttestation); - * } finally { - * $confidentialComputingClient->close(); - * } - * ``` - * - * @param string $challenge Required. The name of the Challenge whose nonce was used to generate the - * attestation, in the format `projects/*/locations/*/challenges/*`. The - * provided Challenge will be consumed, and cannot be used again. - * @param TpmAttestation $tpmAttestation Required. The TPM-specific data provided by the attesting platform, used to - * populate any of the claims regarding platform state. - * @param array $optionalArgs { - * Optional. - * - * @type GcpCredentials $gcpCredentials - * Optional. Credentials used to populate the "emails" claim in the - * claims_token. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\ConfidentialComputing\V1\VerifyAttestationResponse - * - * @throws ApiException if the remote call fails - */ - public function verifyAttestation($challenge, $tpmAttestation, array $optionalArgs = []) - { - $request = new VerifyAttestationRequest(); - $requestParamHeaders = []; - $request->setChallenge($challenge); - $request->setTpmAttestation($tpmAttestation); - $requestParamHeaders['challenge'] = $challenge; - if (isset($optionalArgs['gcpCredentials'])) { - $request->setGcpCredentials($optionalArgs['gcpCredentials']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('VerifyAttestation', VerifyAttestationResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets information about a location. - * - * Sample code: - * ``` - * $confidentialComputingClient = new ConfidentialComputingClient(); - * try { - * $response = $confidentialComputingClient->getLocation(); - * } finally { - * $confidentialComputingClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * Resource name for the location. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Location\Location - * - * @throws ApiException if the remote call fails - */ - public function getLocation(array $optionalArgs = []) - { - $request = new GetLocationRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * Sample code: - * ``` - * $confidentialComputingClient = new ConfidentialComputingClient(); - * try { - * // Iterate over pages of elements - * $pagedResponse = $confidentialComputingClient->listLocations(); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $confidentialComputingClient->listLocations(); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $confidentialComputingClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $name - * The resource that owns the locations collection, if applicable. - * @type string $filter - * The standard list filter. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLocations(array $optionalArgs = []) - { - $request = new ListLocationsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['name'])) { - $request->setName($optionalArgs['name']); - $requestParamHeaders['name'] = $optionalArgs['name']; - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations'); - } -} diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/gapic_metadata.json b/owl-bot-staging/ConfidentialComputing/v1/src/V1/gapic_metadata.json deleted file mode 100644 index b0c5bbf96486..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.confidentialcomputing.v1", - "libraryPackage": "Google\\Cloud\\ConfidentialComputing\\V1", - "services": { - "ConfidentialComputing": { - "clients": { - "grpc": { - "libraryClient": "ConfidentialComputingGapicClient", - "rpcs": { - "CreateChallenge": { - "methods": [ - "createChallenge" - ] - }, - "VerifyAttestation": { - "methods": [ - "verifyAttestation" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_client_config.json b/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_client_config.json deleted file mode 100644 index 142999b0f75f..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_client_config.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "interfaces": { - "google.cloud.confidentialcomputing.v1.ConfidentialComputing": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateChallenge": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "VerifyAttestation": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListLocations": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_descriptor_config.php b/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_descriptor_config.php deleted file mode 100644 index 8ab43815b29c..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_descriptor_config.php +++ /dev/null @@ -1,70 +0,0 @@ - [ - 'google.cloud.confidentialcomputing.v1.ConfidentialComputing' => [ - 'CreateChallenge' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ConfidentialComputing\V1\Challenge', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'VerifyAttestation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ConfidentialComputing\V1\VerifyAttestationResponse', - 'headerParams' => [ - [ - 'keyName' => 'challenge', - 'fieldAccessors' => [ - 'getChallenge', - ], - ], - ], - ], - 'GetLocation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Location\Location', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'ListLocations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLocations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Location\ListLocationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - 'interfaceOverride' => 'google.cloud.location.Locations', - ], - 'templateMap' => [ - 'challenge' => 'projects/{project}/locations/{location}/challenges/{uuid}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_rest_client_config.php b/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_rest_client_config.php deleted file mode 100644 index 364900244c32..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/src/V1/resources/confidential_computing_rest_client_config.php +++ /dev/null @@ -1,57 +0,0 @@ - [ - 'google.cloud.confidentialcomputing.v1.ConfidentialComputing' => [ - 'CreateChallenge' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/challenges', - 'body' => 'challenge', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'VerifyAttestation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{challenge=projects/*/locations/*/challenges/*}:verifyAttestation', - 'body' => '*', - 'placeholders' => [ - 'challenge' => [ - 'getters' => [ - 'getChallenge', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/ConfidentialComputingClientTest.php b/owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/ConfidentialComputingClientTest.php deleted file mode 100644 index ce004aeabb03..000000000000 --- a/owl-bot-staging/ConfidentialComputing/v1/tests/Unit/V1/ConfidentialComputingClientTest.php +++ /dev/null @@ -1,317 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ConfidentialComputingClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ConfidentialComputingClient($options); - } - - /** @test */ - public function createChallengeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $used = false; - $tpmNonce = 'tpmNonce-806632543'; - $expectedResponse = new Challenge(); - $expectedResponse->setName($name); - $expectedResponse->setUsed($used); - $expectedResponse->setTpmNonce($tpmNonce); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $challenge = new Challenge(); - $response = $gapicClient->createChallenge($formattedParent, $challenge); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.confidentialcomputing.v1.ConfidentialComputing/CreateChallenge', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getChallenge(); - $this->assertProtobufEquals($challenge, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createChallengeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $challenge = new Challenge(); - try { - $gapicClient->createChallenge($formattedParent, $challenge); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function verifyAttestationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $oidcClaimsToken = 'oidcClaimsToken1151909399'; - $expectedResponse = new VerifyAttestationResponse(); - $expectedResponse->setOidcClaimsToken($oidcClaimsToken); - $transport->addResponse($expectedResponse); - // Mock request - $formattedChallenge = $gapicClient->challengeName('[PROJECT]', '[LOCATION]', '[UUID]'); - $tpmAttestation = new TpmAttestation(); - $response = $gapicClient->verifyAttestation($formattedChallenge, $tpmAttestation); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.confidentialcomputing.v1.ConfidentialComputing/VerifyAttestation', $actualFuncCall); - $actualValue = $actualRequestObject->getChallenge(); - $this->assertProtobufEquals($formattedChallenge, $actualValue); - $actualValue = $actualRequestObject->getTpmAttestation(); - $this->assertProtobufEquals($tpmAttestation, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function verifyAttestationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedChallenge = $gapicClient->challengeName('[PROJECT]', '[LOCATION]', '[UUID]'); - $tpmAttestation = new TpmAttestation(); - try { - $gapicClient->verifyAttestation($formattedChallenge, $tpmAttestation); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $locationId = 'locationId552319461'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Location(); - $expectedResponse->setName($name2); - $expectedResponse->setLocationId($locationId); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - $response = $gapicClient->getLocation(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/GetLocation', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLocationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->getLocation(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $locationsElement = new Location(); - $locations = [ - $locationsElement, - ]; - $expectedResponse = new ListLocationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLocations($locations); - $transport->addResponse($expectedResponse); - $response = $gapicClient->listLocations(); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLocations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.location.Locations/ListLocations', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLocationsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->listLocations(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/GPBMetadata/Google/Cloud/Datacatalog/Lineage/V1/Lineage.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/GPBMetadata/Google/Cloud/Datacatalog/Lineage/V1/Lineage.php deleted file mode 100644 index decabe03d58d7a577ba39ca7ae93f753da42056a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 10731 zcmb_iPiz}$72mOwH2u>2`!;RU6xi8mp=n5MCEJ!TZMN&!PS$E`XXChKktJ(lPm&?d z%+xb(301UWCAh6P>>dyY1YD4o3m0w(!~rCF1c^gVNN}Mi#ECx_-uG`jW5>zoB$e9Q zp6|Wy{rSE3z4zw3|G?dL(KU6&w9SU$n>BS~PxZG=)onPwQ+4Xgtx`Y}L(VweB=)$(rFCRrp(Xwvu(rHjOPa`Fu`% zOi=C!*~YHvxklAgS5}uEo4!HF$}5ynIZYUqGc88tM~qSV$=p4Js&&KjRQ?lsiB$OG zHaF^4RrP$shySiyUd6I4-!kgfcR;g6bRE21(#5iD>a?bY6hHcc#8PlsaEZ27$tFTnpw@g1UDfwmkCf}B@vo_UfCZn!* z2)U^GjiwpiT~!;V-)z|TsN96Xe(n66ux12_Aq-!RJkF=1F9DA$Lv~A1YDi>S=+TN55dDW8^{&McnX1(S04_t|P6v=70J?#G{1DCc9I^Ns zBT3L8PlSRz!Gk>Ud~WJ8=WDnYWCH>x7VlGUg&u4Y%v3fwX!wFFp#=?&4E~7koUFIp zpL7EE^F>!Vz02b>X%YwXhay1*519zN;6}dU3+?0{^%Z|Aqz~wQ;Sjb!`)(Ya18-GL z&%@)Wk0iHAMOCKHFU9|w>c>~mg_`BLbz`qWAH~EY1(y&qe7|9BG=0;XjH~hKq51m> zCe4wyPVoH_sen9d`;9%aqk`W<15U%*vh2w|*lTG1t5Pfrl!S7a%AwIV&UgsLcg#Je z82&Qqe{R&9<|I*OX#SGeK-ehpggn(_3yNNQoidO{AS0l{^aGT52{>Jn!gTk5_*-Vx z_mVI9r+x4`93~{rlP|@`{Ukgkwl>*9@^N4LRUeA4HSHel|G^>lUl6(+h4lpNb-3-{ zK?s7i;a3Psxc#RDOOTwNABiBQiMeBV4h@=ijgjgjuLZn0M?JpC&U)V zN?jyWblWrZvX(>rlrg~MTq*xBUwE1ydxLx_uBX=4vzajk52N$x!sFFPS@Jc85gJ%d zp`(g2k+HRT4JcUVY9VL^O0G=Hp*!>~9fMWTPIyiWZkeeI_TIv-dB=g1MNO0^`{5_YY-jVrxQnu@4y$&ph3FG)88Wd+P96|ipisLCXEPk#un^ukHGJ2%N z@oh9zZJ3ZpdPrIENS2d|fVfr^Y2_jshfK1bt(5Y`)oePqoP)$c6U=HhpULG{Ai+Qu zSu5r9d$e}WB@XsAhfS4iE&1@BB?%cQy^1u~#&*r?Z?7nNPh^Ppy@ zLJn$=(fEq#w+XlqDVn$~Woia(4^2F>Ji*WO&cZ+A=)4PUYsG`+kt*7c!QAvG-`O#3 zZtiF3V%yf93x$e_9{|0mPyimJrt8Vz_%a%`&2Rga(3Z4j)V9z>#;lti4nDE{I=w_T z8q|KIpfQGfIBSJX@3vw7D-`o8KJKX2Q5=q14w-2wti!I|asCk+V=xcN#`j?G?s1P^ zp{-@nFkm>e`|SvRxm}JcVKf(w5&!|80JbMJu_R=xXsop(N9$eG*8mAPP^C@R9i$aB z#z1;n19b!EZxwWffiqml2$Vi(Lurzt^d^?Ch#sTiNcF;zJ12$Qut?n@{1jaR1clcM z@fRad;=;?9bK1uWnj}6B^A6y3dfP|>?IU#M5Ft3?a%d!CUxB^e4cr}s&(IYH!mu6A z$j04p`STdUMbl_hw_($r!04wb6&?nKGHc{dT-_?~zkz`nFO^w~c`9a?Iu1#Kb_G1r zaZ=I;O9&0ZpcJO2mZ5E4 zU|%-JIFU&R7j9Tmh@G&V!HM1m2Y9xZnSu601--Ro_|@%};dv2uHboN_zKcP@L%W0+ zw9=tMikPOokRqTyuYFHJYIo5%Hr_|Wyr`-`@_=5PVMH!xa7}4gcE`#m3c3(kxzH-q zS;JSp0X4o%U5e9TbI2khw0X|nbhLdm+V&H^fcl8~tm|ll41;iIO&-jeB9LKFJz}+X zpr8RZ6NJ<;#2R+id9tSVu2g(74v8XtSw!0|(4jR4)tU%}o?S(ki-po!I$JrsGfS6> z>xIYA>s>&DOSzQ~O4+p!q1hWnLz&cis1CIVh%bJnt#rO=AOD}AP-U_jAj;S==}LFpi86)l+-0cb244ZWva}3^LLmsOriww zbr+RFliZp8kWz1QZDvC)C;p{^P^)#sa_DOjoJ^YghmLiOJTB&lx0ut-G~~pFgr-`AqV~sC=%&BB^8O#2t~dq6bZf3NdyBb?GuFw zJ98qNze?rNMg9T>P{gL~^mQM;BlBJ*kRur7{TfD>K`)H&2;q;Mvj^*i&eDCAmZ#d^ z({3N15hCG3huS*nv=35Hf|1$OEPTPg2l0b;SyKF9eedEwrQ$!BU!dZH0J8DVhVqaG zmxBx(MEYke((lfk#?)sY@c&Z~W&z9#1p49v zzbl2hPC{V}xl%Q}rPiRnENPkEa)AJ2^qq_zooXDUCU};Bf|8U$>{Shh0%8@d_C-kkLqX#tTEd!ncu~r$9dtrDIZzxz&ZD&y(NsEG z5BG2@dVdEHX3-edRuaOUghJcS*ZlNk)wsWA&eUIU?hdt@RS$nn%2OcmMc`tly+Z6%Z)BG1Wwuhd~nZX%Q^IRB8bqspy+PgTxMZT^aTwR2_i?3tl8;qf@Q;xbGVyWw#r>;Ml+Zdp=>pM4s e%UiSTc3|i-A-VlwRS&sHNLR88fBR@3q5lKbtr^My diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesRequest.php deleted file mode 100644 index 4e8c23adcbb2..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesRequest.php +++ /dev/null @@ -1,206 +0,0 @@ -google.cloud.datacatalog.lineage.v1.BatchSearchLinkProcessesRequest - */ -class BatchSearchLinkProcessesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. An array of links to check for their associated LineageProcesses. - * The maximum number of items in this array is 100. - * If the request contains more than 100 links, it returns the - * `INVALID_ARGUMENT` error. - * Format: `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field repeated string links = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $links; - /** - * The maximum number of processes to return in a single page of the response. - * A page may contain fewer results than this value. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * The page token received from a previous `BatchSearchLinkProcesses` call. - * Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location you want search in the format `projects/*/locations/*` - * @type array|\Google\Protobuf\Internal\RepeatedField $links - * Required. An array of links to check for their associated LineageProcesses. - * The maximum number of items in this array is 100. - * If the request contains more than 100 links, it returns the - * `INVALID_ARGUMENT` error. - * Format: `projects/{project}/locations/{location}/links/{link}`. - * @type int $page_size - * The maximum number of processes to return in a single page of the response. - * A page may contain fewer results than this value. - * @type string $page_token - * The page token received from a previous `BatchSearchLinkProcesses` call. - * Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. An array of links to check for their associated LineageProcesses. - * The maximum number of items in this array is 100. - * If the request contains more than 100 links, it returns the - * `INVALID_ARGUMENT` error. - * Format: `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field repeated string links = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLinks() - { - return $this->links; - } - - /** - * Required. An array of links to check for their associated LineageProcesses. - * The maximum number of items in this array is 100. - * If the request contains more than 100 links, it returns the - * `INVALID_ARGUMENT` error. - * Format: `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field repeated string links = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLinks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->links = $arr; - - return $this; - } - - /** - * The maximum number of processes to return in a single page of the response. - * A page may contain fewer results than this value. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of processes to return in a single page of the response. - * A page may contain fewer results than this value. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token received from a previous `BatchSearchLinkProcesses` call. - * Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token received from a previous `BatchSearchLinkProcesses` call. - * Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 4; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesResponse.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesResponse.php deleted file mode 100644 index 6dd4e7df55b5..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/BatchSearchLinkProcessesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.datacatalog.lineage.v1.BatchSearchLinkProcessesResponse - */ -class BatchSearchLinkProcessesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * An array of processes associated with the specified links. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinks process_links = 1; - */ - private $process_links; - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\ProcessLinks>|\Google\Protobuf\Internal\RepeatedField $process_links - * An array of processes associated with the specified links. - * @type string $next_page_token - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * An array of processes associated with the specified links. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinks process_links = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProcessLinks() - { - return $this->process_links; - } - - /** - * An array of processes associated with the specified links. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinks process_links = 1; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\ProcessLinks>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProcessLinks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\ProcessLinks::class); - $this->process_links = $arr; - - return $this; - } - - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateLineageEventRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateLineageEventRequest.php deleted file mode 100644 index dbe80ec46995..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateLineageEventRequest.php +++ /dev/null @@ -1,170 +0,0 @@ -google.cloud.datacatalog.lineage.v1.CreateLineageEventRequest - */ -class CreateLineageEventRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the run that should own the lineage event. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The lineage event to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_event = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $lineage_event = null; - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The name of the run that should own the lineage event. Please see - * {@see LineageClient::runName()} for help formatting this field. - * @param \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $lineageEvent Required. The lineage event to create. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateLineageEventRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $lineageEvent): self - { - return (new self()) - ->setParent($parent) - ->setLineageEvent($lineageEvent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the run that should own the lineage event. - * @type \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $lineage_event - * Required. The lineage event to create. - * @type string $request_id - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the run that should own the lineage event. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the run that should own the lineage event. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The lineage event to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_event = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent|null - */ - public function getLineageEvent() - { - return $this->lineage_event; - } - - public function hasLineageEvent() - { - return isset($this->lineage_event); - } - - public function clearLineageEvent() - { - unset($this->lineage_event); - } - - /** - * Required. The lineage event to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_event = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent $var - * @return $this - */ - public function setLineageEvent($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent::class); - $this->lineage_event = $var; - - return $this; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateProcessRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateProcessRequest.php deleted file mode 100644 index aa9d1ebaaee6..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateProcessRequest.php +++ /dev/null @@ -1,175 +0,0 @@ -google.cloud.datacatalog.lineage.v1.CreateProcessRequest - */ -class CreateProcessRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the project and its location that should own the - * process. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The process to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $process = null; - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The name of the project and its location that should own the - * process. Please see - * {@see LineageClient::locationName()} for help formatting this field. - * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $process Required. The process to create. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateProcessRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\Process $process): self - { - return (new self()) - ->setParent($parent) - ->setProcess($process); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the project and its location that should own the - * process. - * @type \Google\Cloud\DataCatalog\Lineage\V1\Process $process - * Required. The process to create. - * @type string $request_id - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the project and its location that should own the - * process. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the project and its location that should own the - * process. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The process to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\Process|null - */ - public function getProcess() - { - return $this->process; - } - - public function hasProcess() - { - return isset($this->process); - } - - public function clearProcess() - { - unset($this->process); - } - - /** - * Required. The process to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $var - * @return $this - */ - public function setProcess($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\Process::class); - $this->process = $var; - - return $this; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateRunRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateRunRequest.php deleted file mode 100644 index 67ac72ae8277..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/CreateRunRequest.php +++ /dev/null @@ -1,170 +0,0 @@ -google.cloud.datacatalog.lineage.v1.CreateRunRequest - */ -class CreateRunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the process that should own the run. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The run to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $run = null; - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The name of the process that should own the run. Please see - * {@see LineageClient::processName()} for help formatting this field. - * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $run Required. The run to create. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\CreateRunRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\DataCatalog\Lineage\V1\Run $run): self - { - return (new self()) - ->setParent($parent) - ->setRun($run); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the process that should own the run. - * @type \Google\Cloud\DataCatalog\Lineage\V1\Run $run - * Required. The run to create. - * @type string $request_id - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the process that should own the run. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the process that should own the run. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The run to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\Run|null - */ - public function getRun() - { - return $this->run; - } - - public function hasRun() - { - return isset($this->run); - } - - public function clearRun() - { - unset($this->run); - } - - /** - * Required. The run to create. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $var - * @return $this - */ - public function setRun($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\Run::class); - $this->run = $var; - - return $this; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * - * Generated from protobuf field string request_id = 3; - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteLineageEventRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteLineageEventRequest.php deleted file mode 100644 index 18b9d21a24a2..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteLineageEventRequest.php +++ /dev/null @@ -1,120 +0,0 @@ -google.cloud.datacatalog.lineage.v1.DeleteLineageEventRequest - */ -class DeleteLineageEventRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the lineage event to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true and the lineage event is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - */ - protected $allow_missing = false; - - /** - * @param string $name Required. The name of the lineage event to delete. Please see - * {@see LineageClient::lineageEventName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteLineageEventRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the lineage event to delete. - * @type bool $allow_missing - * If set to true and the lineage event is not found, the request - * succeeds but the server doesn't perform any actions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the lineage event to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the lineage event to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true and the lineage event is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true and the lineage event is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteProcessRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteProcessRequest.php deleted file mode 100644 index 088e68cffa5b..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteProcessRequest.php +++ /dev/null @@ -1,120 +0,0 @@ -google.cloud.datacatalog.lineage.v1.DeleteProcessRequest - */ -class DeleteProcessRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the process to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true and the process is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - */ - protected $allow_missing = false; - - /** - * @param string $name Required. The name of the process to delete. Please see - * {@see LineageClient::processName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteProcessRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the process to delete. - * @type bool $allow_missing - * If set to true and the process is not found, the request - * succeeds but the server doesn't perform any actions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the process to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the process to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true and the process is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true and the process is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteRunRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteRunRequest.php deleted file mode 100644 index bcc506513f22..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/DeleteRunRequest.php +++ /dev/null @@ -1,120 +0,0 @@ -google.cloud.datacatalog.lineage.v1.DeleteRunRequest - */ -class DeleteRunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the run to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set to true and the run is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - */ - protected $allow_missing = false; - - /** - * @param string $name Required. The name of the run to delete. Please see - * {@see LineageClient::runName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\DeleteRunRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the run to delete. - * @type bool $allow_missing - * If set to true and the run is not found, the request - * succeeds but the server doesn't perform any actions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the run to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the run to delete. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * If set to true and the run is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true and the run is not found, the request - * succeeds but the server doesn't perform any actions. - * - * Generated from protobuf field bool allow_missing = 2; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EntityReference.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EntityReference.php deleted file mode 100644 index d226e432446a..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EntityReference.php +++ /dev/null @@ -1,95 +0,0 @@ -google.cloud.datacatalog.lineage.v1.EntityReference - */ -class EntityReference extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Fully Qualified Name of the entity. Useful for referencing - * entities that aren't represented as GCP resources, for example, tables in - * Dataproc Metastore API. - * Examples: - * * `bigquery:dataset.project_id.dataset_id` - * * `bigquery:table.project_id.dataset_id.table_id` - * * `pubsub:project_id.topic_id` - * * `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId` - * - * Generated from protobuf field string fully_qualified_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $fully_qualified_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $fully_qualified_name - * Required. Fully Qualified Name of the entity. Useful for referencing - * entities that aren't represented as GCP resources, for example, tables in - * Dataproc Metastore API. - * Examples: - * * `bigquery:dataset.project_id.dataset_id` - * * `bigquery:table.project_id.dataset_id.table_id` - * * `pubsub:project_id.topic_id` - * * `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. Fully Qualified Name of the entity. Useful for referencing - * entities that aren't represented as GCP resources, for example, tables in - * Dataproc Metastore API. - * Examples: - * * `bigquery:dataset.project_id.dataset_id` - * * `bigquery:table.project_id.dataset_id.table_id` - * * `pubsub:project_id.topic_id` - * * `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId` - * - * Generated from protobuf field string fully_qualified_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFullyQualifiedName() - { - return $this->fully_qualified_name; - } - - /** - * Required. Fully Qualified Name of the entity. Useful for referencing - * entities that aren't represented as GCP resources, for example, tables in - * Dataproc Metastore API. - * Examples: - * * `bigquery:dataset.project_id.dataset_id` - * * `bigquery:table.project_id.dataset_id.table_id` - * * `pubsub:project_id.topic_id` - * * `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId` - * - * Generated from protobuf field string fully_qualified_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFullyQualifiedName($var) - { - GPBUtil::checkString($var, True); - $this->fully_qualified_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EventLink.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EventLink.php deleted file mode 100644 index 8d1247a25be5..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/EventLink.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.datacatalog.lineage.v1.EventLink - */ -class EventLink extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Reference to the source entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - /** - * Required. Reference to the target entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $target = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $source - * Required. Reference to the source entity - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $target - * Required. Reference to the target entity - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. Reference to the source entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. Reference to the source entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->source = $var; - - return $this; - } - - /** - * Required. Reference to the target entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getTarget() - { - return $this->target; - } - - public function hasTarget() - { - return isset($this->target); - } - - public function clearTarget() - { - unset($this->target); - } - - /** - * Required. Reference to the target entity - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->target = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetLineageEventRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetLineageEventRequest.php deleted file mode 100644 index bcfbb6140411..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetLineageEventRequest.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.datacatalog.lineage.v1.GetLineageEventRequest - */ -class GetLineageEventRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the lineage event to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the lineage event to get. Please see - * {@see LineageClient::lineageEventName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\GetLineageEventRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the lineage event to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the lineage event to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the lineage event to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetProcessRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetProcessRequest.php deleted file mode 100644 index 7f23ce58f182..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetProcessRequest.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.datacatalog.lineage.v1.GetProcessRequest - */ -class GetProcessRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the process to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the process to get. Please see - * {@see LineageClient::processName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\GetProcessRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the process to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the process to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the process to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetRunRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetRunRequest.php deleted file mode 100644 index b0f0b84a2848..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/GetRunRequest.php +++ /dev/null @@ -1,82 +0,0 @@ -google.cloud.datacatalog.lineage.v1.GetRunRequest - */ -class GetRunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the run to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the run to get. Please see - * {@see LineageClient::runName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\GetRunRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the run to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the run to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the run to get. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageEvent.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageEvent.php deleted file mode 100644 index 8a7f7044abf9..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageEvent.php +++ /dev/null @@ -1,226 +0,0 @@ -google.cloud.datacatalog.lineage.v1.LineageEvent - */ -class LineageEvent extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The resource name of the lineage event. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}`. - * Can be specified or auto-assigned. - * {lineage_event} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Optional. List of source-target pairs. Can't contain more than 100 tuples. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.EventLink links = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $links; - /** - * Optional. The beginning of the transformation which resulted in this - * lineage event. For streaming scenarios, it should be the beginning of the - * period from which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $start_time = null; - /** - * Optional. The end of the transformation which resulted in this lineage - * event. For streaming scenarios, it should be the end of the period from - * which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. The resource name of the lineage event. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}`. - * Can be specified or auto-assigned. - * {lineage_event} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\EventLink>|\Google\Protobuf\Internal\RepeatedField $links - * Optional. List of source-target pairs. Can't contain more than 100 tuples. - * @type \Google\Protobuf\Timestamp $start_time - * Optional. The beginning of the transformation which resulted in this - * lineage event. For streaming scenarios, it should be the beginning of the - * period from which the lineage is being reported. - * @type \Google\Protobuf\Timestamp $end_time - * Optional. The end of the transformation which resulted in this lineage - * event. For streaming scenarios, it should be the end of the period from - * which the lineage is being reported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The resource name of the lineage event. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}`. - * Can be specified or auto-assigned. - * {lineage_event} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. The resource name of the lineage event. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}`. - * Can be specified or auto-assigned. - * {lineage_event} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. List of source-target pairs. Can't contain more than 100 tuples. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.EventLink links = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLinks() - { - return $this->links; - } - - /** - * Optional. List of source-target pairs. Can't contain more than 100 tuples. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.EventLink links = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\EventLink>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLinks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\EventLink::class); - $this->links = $arr; - - return $this; - } - - /** - * Optional. The beginning of the transformation which resulted in this - * lineage event. For streaming scenarios, it should be the beginning of the - * period from which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Optional. The beginning of the transformation which resulted in this - * lineage event. For streaming scenarios, it should be the beginning of the - * period from which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Optional. The end of the transformation which resulted in this lineage - * event. For streaming scenarios, it should be the end of the period from - * which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Optional. The end of the transformation which resulted in this lineage - * event. For streaming scenarios, it should be the end of the period from - * which the lineage is being reported. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageGrpcClient.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageGrpcClient.php deleted file mode 100644 index eeb56d84cdac..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/LineageGrpcClient.php +++ /dev/null @@ -1,302 +0,0 @@ -_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/CreateProcess', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Process', 'decode'], - $metadata, $options); - } - - /** - * Updates a process. - * @param \Google\Cloud\DataCatalog\Lineage\V1\UpdateProcessRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateProcess(\Google\Cloud\DataCatalog\Lineage\V1\UpdateProcessRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/UpdateProcess', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Process', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of the specified process. - * @param \Google\Cloud\DataCatalog\Lineage\V1\GetProcessRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetProcess(\Google\Cloud\DataCatalog\Lineage\V1\GetProcessRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/GetProcess', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Process', 'decode'], - $metadata, $options); - } - - /** - * List processes in the given project and location. List order is descending - * by insertion time. - * @param \Google\Cloud\DataCatalog\Lineage\V1\ListProcessesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListProcesses(\Google\Cloud\DataCatalog\Lineage\V1\ListProcessesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/ListProcesses', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\ListProcessesResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes the process with the specified name. - * @param \Google\Cloud\DataCatalog\Lineage\V1\DeleteProcessRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteProcess(\Google\Cloud\DataCatalog\Lineage\V1\DeleteProcessRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteProcess', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Creates a new run. - * @param \Google\Cloud\DataCatalog\Lineage\V1\CreateRunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateRun(\Google\Cloud\DataCatalog\Lineage\V1\CreateRunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/CreateRun', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Run', 'decode'], - $metadata, $options); - } - - /** - * Updates a run. - * @param \Google\Cloud\DataCatalog\Lineage\V1\UpdateRunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateRun(\Google\Cloud\DataCatalog\Lineage\V1\UpdateRunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/UpdateRun', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Run', 'decode'], - $metadata, $options); - } - - /** - * Gets the details of the specified run. - * @param \Google\Cloud\DataCatalog\Lineage\V1\GetRunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetRun(\Google\Cloud\DataCatalog\Lineage\V1\GetRunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/GetRun', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\Run', 'decode'], - $metadata, $options); - } - - /** - * Lists runs in the given project and location. List order is descending by - * `start_time`. - * @param \Google\Cloud\DataCatalog\Lineage\V1\ListRunsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListRuns(\Google\Cloud\DataCatalog\Lineage\V1\ListRunsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/ListRuns', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\ListRunsResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes the run with the specified name. - * @param \Google\Cloud\DataCatalog\Lineage\V1\DeleteRunRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteRun(\Google\Cloud\DataCatalog\Lineage\V1\DeleteRunRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteRun', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Creates a new lineage event. - * @param \Google\Cloud\DataCatalog\Lineage\V1\CreateLineageEventRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateLineageEvent(\Google\Cloud\DataCatalog\Lineage\V1\CreateLineageEventRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/CreateLineageEvent', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a specified lineage event. - * @param \Google\Cloud\DataCatalog\Lineage\V1\GetLineageEventRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetLineageEvent(\Google\Cloud\DataCatalog\Lineage\V1\GetLineageEventRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/GetLineageEvent', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', 'decode'], - $metadata, $options); - } - - /** - * Lists lineage events in the given project and location. The list order is - * not defined. - * @param \Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListLineageEvents(\Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/ListLineageEvents', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsResponse', 'decode'], - $metadata, $options); - } - - /** - * Deletes the lineage event with the specified name. - * @param \Google\Cloud\DataCatalog\Lineage\V1\DeleteLineageEventRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteLineageEvent(\Google\Cloud\DataCatalog\Lineage\V1\DeleteLineageEventRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteLineageEvent', - $argument, - ['\Google\Protobuf\GPBEmpty', 'decode'], - $metadata, $options); - } - - /** - * Retrieve a list of links connected to a specific asset. - * Links represent the data flow between **source** (upstream) - * and **target** (downstream) assets in transformation pipelines. - * Links are stored in the same project as the Lineage Events that create - * them. - * - * You can retrieve links in every project where you have the - * `datalineage.events.get` permission. The project provided in the URL - * is used for Billing and Quota. - * @param \Google\Cloud\DataCatalog\Lineage\V1\SearchLinksRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function SearchLinks(\Google\Cloud\DataCatalog\Lineage\V1\SearchLinksRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/SearchLinks', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\SearchLinksResponse', 'decode'], - $metadata, $options); - } - - /** - * Retrieve information about LineageProcesses associated with specific - * links. LineageProcesses are transformation pipelines that result in data - * flowing from **source** to **target** assets. Links between assets - * represent this operation. - * - * If you have specific link names, you can use this method to - * verify which LineageProcesses contribute to creating those links. - * See the - * [SearchLinks][google.cloud.datacatalog.lineage.v1.Lineage.SearchLinks] - * method for more information on how to retrieve link name. - * - * You can retrieve the LineageProcess information in every project where you - * have the `datalineage.events.get` permission. The project provided in the - * URL is used for Billing and Quota. - * @param \Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function BatchSearchLinkProcesses(\Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datacatalog.lineage.v1.Lineage/BatchSearchLinkProcesses', - $argument, - ['\Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesResponse', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Link.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Link.php deleted file mode 100644 index bc87e154dbeb..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Link.php +++ /dev/null @@ -1,250 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Link - */ -class Link extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Immutable. The name of the link. Format: - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * The pointer to the entity that is the **source** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 2; - */ - protected $source = null; - /** - * The pointer to the entity that is the **target** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 3; - */ - protected $target = null; - /** - * The start of the first event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4; - */ - protected $start_time = null; - /** - * The end of the last event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Immutable. The name of the link. Format: - * `projects/{project}/locations/{location}/links/{link}`. - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $source - * The pointer to the entity that is the **source** of this link. - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $target - * The pointer to the entity that is the **target** of this link. - * @type \Google\Protobuf\Timestamp $start_time - * The start of the first event establishing this link. - * @type \Google\Protobuf\Timestamp $end_time - * The end of the last event establishing this link. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Immutable. The name of the link. Format: - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Immutable. The name of the link. Format: - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The pointer to the entity that is the **source** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 2; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * The pointer to the entity that is the **source** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 2; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->source = $var; - - return $this; - } - - /** - * The pointer to the entity that is the **target** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 3; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getTarget() - { - return $this->target; - } - - public function hasTarget() - { - return isset($this->target); - } - - public function clearTarget() - { - unset($this->target); - } - - /** - * The pointer to the entity that is the **target** of this link. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 3; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->target = $var; - - return $this; - } - - /** - * The start of the first event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * The start of the first event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * The end of the last event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The end of the last event establishing this link. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsRequest.php deleted file mode 100644 index 02a1847041af..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsRequest.php +++ /dev/null @@ -1,178 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListLineageEventsRequest - */ -class ListLineageEventsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the run that owns the collection of lineage events to - * get. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of lineage events to return. - * The service may return fewer events than this value. - * If unspecified, at most 50 events are returned. The maximum value is 100; - * values greater than 100 are cut to 100. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token received from a previous `ListLineageEvents` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The name of the run that owns the collection of lineage events to - * get. Please see {@see LineageClient::runName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the run that owns the collection of lineage events to - * get. - * @type int $page_size - * The maximum number of lineage events to return. - * The service may return fewer events than this value. - * If unspecified, at most 50 events are returned. The maximum value is 100; - * values greater than 100 are cut to 100. - * @type string $page_token - * The page token received from a previous `ListLineageEvents` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the run that owns the collection of lineage events to - * get. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the run that owns the collection of lineage events to - * get. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of lineage events to return. - * The service may return fewer events than this value. - * If unspecified, at most 50 events are returned. The maximum value is 100; - * values greater than 100 are cut to 100. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of lineage events to return. - * The service may return fewer events than this value. - * If unspecified, at most 50 events are returned. The maximum value is 100; - * values greater than 100 are cut to 100. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token received from a previous `ListLineageEvents` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token received from a previous `ListLineageEvents` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsResponse.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsResponse.php deleted file mode 100644 index 1543999a54a6..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListLineageEventsResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListLineageEventsResponse - */ -class ListLineageEventsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Lineage events from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_events = 1; - */ - private $lineage_events; - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\LineageEvent>|\Google\Protobuf\Internal\RepeatedField $lineage_events - * Lineage events from the specified project and location. - * @type string $next_page_token - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Lineage events from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_events = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLineageEvents() - { - return $this->lineage_events; - } - - /** - * Lineage events from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.LineageEvent lineage_events = 1; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\LineageEvent>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLineageEvents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent::class); - $this->lineage_events = $arr; - - return $this; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesRequest.php deleted file mode 100644 index 1b81bb00d128..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesRequest.php +++ /dev/null @@ -1,179 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListProcessesRequest - */ -class ListProcessesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the project and its location that owns this - * collection of processes. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of processes to return. The service may return - * fewer than this value. If unspecified, at most 50 processes are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token received from a previous `ListProcesses` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The name of the project and its location that owns this - * collection of processes. Please see - * {@see LineageClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\ListProcessesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the project and its location that owns this - * collection of processes. - * @type int $page_size - * The maximum number of processes to return. The service may return - * fewer than this value. If unspecified, at most 50 processes are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * @type string $page_token - * The page token received from a previous `ListProcesses` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the project and its location that owns this - * collection of processes. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the project and its location that owns this - * collection of processes. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of processes to return. The service may return - * fewer than this value. If unspecified, at most 50 processes are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of processes to return. The service may return - * fewer than this value. If unspecified, at most 50 processes are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token received from a previous `ListProcesses` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token received from a previous `ListProcesses` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesResponse.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesResponse.php deleted file mode 100644 index 075a0e6e3dc4..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListProcessesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListProcessesResponse - */ -class ListProcessesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The processes from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Process processes = 1; - */ - private $processes; - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\Process>|\Google\Protobuf\Internal\RepeatedField $processes - * The processes from the specified project and location. - * @type string $next_page_token - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * The processes from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Process processes = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProcesses() - { - return $this->processes; - } - - /** - * The processes from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Process processes = 1; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\Process>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProcesses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\Process::class); - $this->processes = $arr; - - return $this; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsRequest.php deleted file mode 100644 index 6a762c1e9dcd..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsRequest.php +++ /dev/null @@ -1,174 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListRunsRequest - */ -class ListRunsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of process that owns this collection of runs. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of runs to return. The service may return - * fewer than this value. If unspecified, at most 50 runs are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The page token received from a previous `ListRuns` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The name of process that owns this collection of runs. Please see - * {@see LineageClient::processName()} for help formatting this field. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\ListRunsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of process that owns this collection of runs. - * @type int $page_size - * The maximum number of runs to return. The service may return - * fewer than this value. If unspecified, at most 50 runs are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * @type string $page_token - * The page token received from a previous `ListRuns` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of process that owns this collection of runs. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of process that owns this collection of runs. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of runs to return. The service may return - * fewer than this value. If unspecified, at most 50 runs are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of runs to return. The service may return - * fewer than this value. If unspecified, at most 50 runs are - * returned. The maximum value is 100; values greater than 100 are cut to - * 100. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The page token received from a previous `ListRuns` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The page token received from a previous `ListRuns` call. Specify - * it to get the next page. - * When paginating, all other parameters specified in this call must - * match the parameters of the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsResponse.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsResponse.php deleted file mode 100644 index ad73a867f0ca..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ListRunsResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ListRunsResponse - */ -class ListRunsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The runs from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Run runs = 1; - */ - private $runs; - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\Run>|\Google\Protobuf\Internal\RepeatedField $runs - * The runs from the specified project and location. - * @type string $next_page_token - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * The runs from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Run runs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRuns() - { - return $this->runs; - } - - /** - * The runs from the specified project and location. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Run runs = 1; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\Run>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRuns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\Run::class); - $this->runs = $arr; - - return $this; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The token to specify as `page_token` in the next call to get the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata.php deleted file mode 100644 index 4043b7e1dd3c..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata.php +++ /dev/null @@ -1,269 +0,0 @@ -google.cloud.datacatalog.lineage.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The current operation state. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. The type of the operation being performed. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.Type operation_type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $operation_type = 0; - /** - * Output only. The [relative name] - * (https://cloud.google.com//apis/design/resource_names#relative_resource_name) - * of the resource being operated on. - * - * Generated from protobuf field string resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource = ''; - /** - * Output only. The UUID of the resource being operated on. - * - * Generated from protobuf field string resource_uuid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource_uuid = ''; - /** - * Output only. The timestamp of the operation submission to the server. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The timestamp of the operation termination, regardless of its - * success. This field is unset if the operation is still ongoing. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * Output only. The current operation state. - * @type int $operation_type - * Output only. The type of the operation being performed. - * @type string $resource - * Output only. The [relative name] - * (https://cloud.google.com//apis/design/resource_names#relative_resource_name) - * of the resource being operated on. - * @type string $resource_uuid - * Output only. The UUID of the resource being operated on. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The timestamp of the operation submission to the server. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. The timestamp of the operation termination, regardless of its - * success. This field is unset if the operation is still ongoing. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The current operation state. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current operation state. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. The type of the operation being performed. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.Type operation_type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getOperationType() - { - return $this->operation_type; - } - - /** - * Output only. The type of the operation being performed. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.OperationMetadata.Type operation_type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setOperationType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata\Type::class); - $this->operation_type = $var; - - return $this; - } - - /** - * Output only. The [relative name] - * (https://cloud.google.com//apis/design/resource_names#relative_resource_name) - * of the resource being operated on. - * - * Generated from protobuf field string resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * Output only. The [relative name] - * (https://cloud.google.com//apis/design/resource_names#relative_resource_name) - * of the resource being operated on. - * - * Generated from protobuf field string resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * Output only. The UUID of the resource being operated on. - * - * Generated from protobuf field string resource_uuid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getResourceUuid() - { - return $this->resource_uuid; - } - - /** - * Output only. The UUID of the resource being operated on. - * - * Generated from protobuf field string resource_uuid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setResourceUuid($var) - { - GPBUtil::checkString($var, True); - $this->resource_uuid = $var; - - return $this; - } - - /** - * Output only. The timestamp of the operation submission to the server. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The timestamp of the operation submission to the server. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The timestamp of the operation termination, regardless of its - * success. This field is unset if the operation is still ongoing. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Output only. The timestamp of the operation termination, regardless of its - * success. This field is unset if the operation is still ongoing. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/State.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/State.php deleted file mode 100644 index 5dcdd98eed98..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/State.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.datacatalog.lineage.v1.OperationMetadata.State - */ -class State -{ - /** - * Unused. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The operation has been created but is not yet started. - * - * Generated from protobuf enum PENDING = 1; - */ - const PENDING = 1; - /** - * The operation is underway. - * - * Generated from protobuf enum RUNNING = 2; - */ - const RUNNING = 2; - /** - * The operation completed successfully. - * - * Generated from protobuf enum SUCCEEDED = 3; - */ - const SUCCEEDED = 3; - /** - * The operation is no longer running and did not succeed. - * - * Generated from protobuf enum FAILED = 4; - */ - const FAILED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::PENDING => 'PENDING', - self::RUNNING => 'RUNNING', - self::SUCCEEDED => 'SUCCEEDED', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata_State::class); - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/Type.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/Type.php deleted file mode 100644 index d62736e0cf35..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata/Type.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.datacatalog.lineage.v1.OperationMetadata.Type - */ -class Type -{ - /** - * Unused. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * The resource deletion operation. - * - * Generated from protobuf enum DELETE = 1; - */ - const DELETE = 1; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::DELETE => 'DELETE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata_Type::class); - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata_State.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata_State.php deleted file mode 100644 index 76f7a45e3fa2..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/OperationMetadata_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Origin - */ -class Origin extends \Google\Protobuf\Internal\Message -{ - /** - * Type of the source. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin.SourceType source_type = 1; - */ - protected $source_type = 0; - /** - * If the source_type isn't CUSTOM, the value of this field should be a GCP - * resource name of the system, which reports lineage. The project and - * location parts of the resource name must match the project and location of - * the lineage resource being created. Examples: - * - `{source_type: COMPOSER, name: - * "projects/foo/locations/us/environments/bar"}` - * - `{source_type: BIGQUERY, name: "projects/foo/locations/eu"}` - * - `{source_type: CUSTOM, name: "myCustomIntegration"}` - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $source_type - * Type of the source. - * @type string $name - * If the source_type isn't CUSTOM, the value of this field should be a GCP - * resource name of the system, which reports lineage. The project and - * location parts of the resource name must match the project and location of - * the lineage resource being created. Examples: - * - `{source_type: COMPOSER, name: - * "projects/foo/locations/us/environments/bar"}` - * - `{source_type: BIGQUERY, name: "projects/foo/locations/eu"}` - * - `{source_type: CUSTOM, name: "myCustomIntegration"}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Type of the source. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin.SourceType source_type = 1; - * @return int - */ - public function getSourceType() - { - return $this->source_type; - } - - /** - * Type of the source. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin.SourceType source_type = 1; - * @param int $var - * @return $this - */ - public function setSourceType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataCatalog\Lineage\V1\Origin\SourceType::class); - $this->source_type = $var; - - return $this; - } - - /** - * If the source_type isn't CUSTOM, the value of this field should be a GCP - * resource name of the system, which reports lineage. The project and - * location parts of the resource name must match the project and location of - * the lineage resource being created. Examples: - * - `{source_type: COMPOSER, name: - * "projects/foo/locations/us/environments/bar"}` - * - `{source_type: BIGQUERY, name: "projects/foo/locations/eu"}` - * - `{source_type: CUSTOM, name: "myCustomIntegration"}` - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * If the source_type isn't CUSTOM, the value of this field should be a GCP - * resource name of the system, which reports lineage. The project and - * location parts of the resource name must match the project and location of - * the lineage resource being created. Examples: - * - `{source_type: COMPOSER, name: - * "projects/foo/locations/us/environments/bar"}` - * - `{source_type: BIGQUERY, name: "projects/foo/locations/eu"}` - * - `{source_type: CUSTOM, name: "myCustomIntegration"}` - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin/SourceType.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin/SourceType.php deleted file mode 100644 index 3b29744c1285..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin/SourceType.php +++ /dev/null @@ -1,85 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Origin.SourceType - */ -class SourceType -{ - /** - * Source is Unspecified - * - * Generated from protobuf enum SOURCE_TYPE_UNSPECIFIED = 0; - */ - const SOURCE_TYPE_UNSPECIFIED = 0; - /** - * A custom source - * - * Generated from protobuf enum CUSTOM = 1; - */ - const CUSTOM = 1; - /** - * BigQuery - * - * Generated from protobuf enum BIGQUERY = 2; - */ - const BIGQUERY = 2; - /** - * Data Fusion - * - * Generated from protobuf enum DATA_FUSION = 3; - */ - const DATA_FUSION = 3; - /** - * Composer - * - * Generated from protobuf enum COMPOSER = 4; - */ - const COMPOSER = 4; - /** - * Looker Studio - * - * Generated from protobuf enum LOOKER_STUDIO = 5; - */ - const LOOKER_STUDIO = 5; - - private static $valueToName = [ - self::SOURCE_TYPE_UNSPECIFIED => 'SOURCE_TYPE_UNSPECIFIED', - self::CUSTOM => 'CUSTOM', - self::BIGQUERY => 'BIGQUERY', - self::DATA_FUSION => 'DATA_FUSION', - self::COMPOSER => 'COMPOSER', - self::LOOKER_STUDIO => 'LOOKER_STUDIO', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SourceType::class, \Google\Cloud\DataCatalog\Lineage\V1\Origin_SourceType::class); - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin_SourceType.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin_SourceType.php deleted file mode 100644 index 9ad01664a52a..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Origin_SourceType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Process - */ -class Process extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The resource name of the lineage process. Format: - * `projects/{project}/locations/{location}/processes/{process}`. - * Can be specified or auto-assigned. - * {process} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 200 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Optional. The attributes of the process. Can be anything, for example, - * "author". Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $attributes; - /** - * Optional. The origin of this process and its runs and lineage events. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin origin = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $origin = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. The resource name of the lineage process. Format: - * `projects/{project}/locations/{location}/processes/{process}`. - * Can be specified or auto-assigned. - * {process} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * @type string $display_name - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 200 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * @type array|\Google\Protobuf\Internal\MapField $attributes - * Optional. The attributes of the process. Can be anything, for example, - * "author". Up to 100 attributes are allowed. - * @type \Google\Cloud\DataCatalog\Lineage\V1\Origin $origin - * Optional. The origin of this process and its runs and lineage events. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The resource name of the lineage process. Format: - * `projects/{project}/locations/{location}/processes/{process}`. - * Can be specified or auto-assigned. - * {process} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. The resource name of the lineage process. Format: - * `projects/{project}/locations/{location}/processes/{process}`. - * Can be specified or auto-assigned. - * {process} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 200 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 200 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. The attributes of the process. Can be anything, for example, - * "author". Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAttributes() - { - return $this->attributes; - } - - /** - * Optional. The attributes of the process. Can be anything, for example, - * "author". Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAttributes($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->attributes = $arr; - - return $this; - } - - /** - * Optional. The origin of this process and its runs and lineage events. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin origin = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\Origin|null - */ - public function getOrigin() - { - return $this->origin; - } - - public function hasOrigin() - { - return isset($this->origin); - } - - public function clearOrigin() - { - unset($this->origin); - } - - /** - * Optional. The origin of this process and its runs and lineage events. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Origin origin = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\Origin $var - * @return $this - */ - public function setOrigin($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\Origin::class); - $this->origin = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinkInfo.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinkInfo.php deleted file mode 100644 index 2b02891300f5..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinkInfo.php +++ /dev/null @@ -1,159 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ProcessLinkInfo - */ -class ProcessLinkInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the link in the format of - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string link = 1; - */ - protected $link = ''; - /** - * The start of the first event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2; - */ - protected $start_time = null; - /** - * The end of the last event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3; - */ - protected $end_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $link - * The name of the link in the format of - * `projects/{project}/locations/{location}/links/{link}`. - * @type \Google\Protobuf\Timestamp $start_time - * The start of the first event establishing this link-process tuple. - * @type \Google\Protobuf\Timestamp $end_time - * The end of the last event establishing this link-process tuple. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * The name of the link in the format of - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string link = 1; - * @return string - */ - public function getLink() - { - return $this->link; - } - - /** - * The name of the link in the format of - * `projects/{project}/locations/{location}/links/{link}`. - * - * Generated from protobuf field string link = 1; - * @param string $var - * @return $this - */ - public function setLink($var) - { - GPBUtil::checkString($var, True); - $this->link = $var; - - return $this; - } - - /** - * The start of the first event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * The start of the first event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * The end of the last event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The end of the last event establishing this link-process tuple. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinks.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinks.php deleted file mode 100644 index dc67efad53f0..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/ProcessLinks.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.datacatalog.lineage.v1.ProcessLinks - */ -class ProcessLinks extends \Google\Protobuf\Internal\Message -{ - /** - * The process name in the format of - * `projects/{project}/locations/{location}/processes/{process}`. - * - * Generated from protobuf field string process = 1 [(.google.api.resource_reference) = { - */ - protected $process = ''; - /** - * An array containing link details objects of the links provided in - * the original request. - * A single process can result in creating multiple links. - * If any of the links you provide in the request are created by - * the same process, they all are included in this array. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinkInfo links = 2; - */ - private $links; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $process - * The process name in the format of - * `projects/{project}/locations/{location}/processes/{process}`. - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\ProcessLinkInfo>|\Google\Protobuf\Internal\RepeatedField $links - * An array containing link details objects of the links provided in - * the original request. - * A single process can result in creating multiple links. - * If any of the links you provide in the request are created by - * the same process, they all are included in this array. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * The process name in the format of - * `projects/{project}/locations/{location}/processes/{process}`. - * - * Generated from protobuf field string process = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getProcess() - { - return $this->process; - } - - /** - * The process name in the format of - * `projects/{project}/locations/{location}/processes/{process}`. - * - * Generated from protobuf field string process = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setProcess($var) - { - GPBUtil::checkString($var, True); - $this->process = $var; - - return $this; - } - - /** - * An array containing link details objects of the links provided in - * the original request. - * A single process can result in creating multiple links. - * If any of the links you provide in the request are created by - * the same process, they all are included in this array. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinkInfo links = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLinks() - { - return $this->links; - } - - /** - * An array containing link details objects of the links provided in - * the original request. - * A single process can result in creating multiple links. - * If any of the links you provide in the request are created by - * the same process, they all are included in this array. - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.ProcessLinkInfo links = 2; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\ProcessLinkInfo>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLinks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\ProcessLinkInfo::class); - $this->links = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run.php deleted file mode 100644 index ffc30d399699..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run.php +++ /dev/null @@ -1,286 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Run - */ -class Run extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The resource name of the run. Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * Can be specified or auto-assigned. - * {run} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 1024 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Optional. The attributes of the run. Can be anything, for example, a string - * with an SQL request. Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $attributes; - /** - * Required. The timestamp of the start of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $start_time = null; - /** - * Optional. The timestamp of the end of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $end_time = null; - /** - * Required. The state of the run. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run.State state = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. The resource name of the run. Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * Can be specified or auto-assigned. - * {run} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * @type string $display_name - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 1024 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * @type array|\Google\Protobuf\Internal\MapField $attributes - * Optional. The attributes of the run. Can be anything, for example, a string - * with an SQL request. Up to 100 attributes are allowed. - * @type \Google\Protobuf\Timestamp $start_time - * Required. The timestamp of the start of the run. - * @type \Google\Protobuf\Timestamp $end_time - * Optional. The timestamp of the end of the run. - * @type int $state - * Required. The state of the run. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The resource name of the run. Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * Can be specified or auto-assigned. - * {run} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. The resource name of the run. Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * Can be specified or auto-assigned. - * {run} must be not longer than 200 characters and only - * contain characters in a set: `a-zA-Z0-9_-:.` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 1024 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. A human-readable name you can set to display in a user interface. - * Must be not longer than 1024 characters and only contain UTF-8 letters - * or numbers, spaces or characters like `_-:&.` - * - * Generated from protobuf field string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. The attributes of the run. Can be anything, for example, a string - * with an SQL request. Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAttributes() - { - return $this->attributes; - } - - /** - * Optional. The attributes of the run. Can be anything, for example, a string - * with an SQL request. Up to 100 attributes are allowed. - * - * Generated from protobuf field map attributes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAttributes($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->attributes = $arr; - - return $this; - } - - /** - * Required. The timestamp of the start of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Required. The timestamp of the start of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - - /** - * Optional. The timestamp of the end of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * Optional. The timestamp of the end of the run. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Required. The state of the run. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run.State state = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Required. The state of the run. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run.State state = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataCatalog\Lineage\V1\Run\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run/State.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run/State.php deleted file mode 100644 index 7fce45aebf28..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run/State.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.datacatalog.lineage.v1.Run.State - */ -class State -{ - /** - * The state is unknown. The true state may be any of the below or a - * different state that is not supported here explicitly. - * - * Generated from protobuf enum UNKNOWN = 0; - */ - const UNKNOWN = 0; - /** - * The run is still executing. - * - * Generated from protobuf enum STARTED = 1; - */ - const STARTED = 1; - /** - * The run completed. - * - * Generated from protobuf enum COMPLETED = 2; - */ - const COMPLETED = 2; - /** - * The run failed. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - /** - * The run aborted. - * - * Generated from protobuf enum ABORTED = 4; - */ - const ABORTED = 4; - - private static $valueToName = [ - self::UNKNOWN => 'UNKNOWN', - self::STARTED => 'STARTED', - self::COMPLETED => 'COMPLETED', - self::FAILED => 'FAILED', - self::ABORTED => 'ABORTED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\DataCatalog\Lineage\V1\Run_State::class); - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run_State.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run_State.php deleted file mode 100644 index 333163d9533d..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/Run_State.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.datacatalog.lineage.v1.SearchLinksRequest - */ -class SearchLinksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of links to return in a single page of the - * response. A page may contain fewer links than this value. If unspecified, - * at most 10 links are returned. - * Maximum value is 100; values greater than 100 are reduced to 100. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The page token received from a previous `SearchLinksRequest` - * call. Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - protected $criteria; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location you want search in the format `projects/*/locations/*` - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $source - * Optional. Send asset information in the **source** field to retrieve all - * links that lead from the specified asset to downstream assets. - * @type \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $target - * Optional. Send asset information in the **target** field to retrieve all - * links that lead from upstream assets to the specified asset. - * @type int $page_size - * Optional. The maximum number of links to return in a single page of the - * response. A page may contain fewer links than this value. If unspecified, - * at most 10 links are returned. - * Maximum value is 100; values greater than 100 are reduced to 100. - * @type string $page_token - * Optional. The page token received from a previous `SearchLinksRequest` - * call. Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location you want search in the format `projects/*/locations/*` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. Send asset information in the **source** field to retrieve all - * links that lead from the specified asset to downstream assets. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getSource() - { - return $this->readOneof(4); - } - - public function hasSource() - { - return $this->hasOneof(4); - } - - /** - * Optional. Send asset information in the **source** field to retrieve all - * links that lead from the specified asset to downstream assets. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference source = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Optional. Send asset information in the **target** field to retrieve all - * links that lead from upstream assets to the specified asset. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\EntityReference|null - */ - public function getTarget() - { - return $this->readOneof(5); - } - - public function hasTarget() - { - return $this->hasOneof(5); - } - - /** - * Optional. Send asset information in the **target** field to retrieve all - * links that lead from upstream assets to the specified asset. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.EntityReference target = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\EntityReference $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\EntityReference::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Optional. The maximum number of links to return in a single page of the - * response. A page may contain fewer links than this value. If unspecified, - * at most 10 links are returned. - * Maximum value is 100; values greater than 100 are reduced to 100. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of links to return in a single page of the - * response. A page may contain fewer links than this value. If unspecified, - * at most 10 links are returned. - * Maximum value is 100; values greater than 100 are reduced to 100. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The page token received from a previous `SearchLinksRequest` - * call. Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The page token received from a previous `SearchLinksRequest` - * call. Use it to get the next page. - * When requesting subsequent pages of a response, remember that - * all parameters must match the values you provided - * in the original request. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * @return string - */ - public function getCriteria() - { - return $this->whichOneof("criteria"); - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/SearchLinksResponse.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/SearchLinksResponse.php deleted file mode 100644 index e54d2eb0e0fe..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/SearchLinksResponse.php +++ /dev/null @@ -1,110 +0,0 @@ -google.cloud.datacatalog.lineage.v1.SearchLinksResponse - */ -class SearchLinksResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of links for a given asset. Can be empty if the asset has no - * relations of requested type (source or target). - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Link links = 1; - */ - private $links; - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataCatalog\Lineage\V1\Link>|\Google\Protobuf\Internal\RepeatedField $links - * The list of links for a given asset. Can be empty if the asset has no - * relations of requested type (source or target). - * @type string $next_page_token - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * The list of links for a given asset. Can be empty if the asset has no - * relations of requested type (source or target). - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Link links = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLinks() - { - return $this->links; - } - - /** - * The list of links for a given asset. Can be empty if the asset has no - * relations of requested type (source or target). - * - * Generated from protobuf field repeated .google.cloud.datacatalog.lineage.v1.Link links = 1; - * @param array<\Google\Cloud\DataCatalog\Lineage\V1\Link>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLinks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataCatalog\Lineage\V1\Link::class); - $this->links = $arr; - - return $this; - } - - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * The token to specify as `page_token` in the subsequent call to get the next - * page. Omitted if there are no more pages in the response. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateProcessRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateProcessRequest.php deleted file mode 100644 index 9b26ec7372de..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateProcessRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.cloud.datacatalog.lineage.v1.UpdateProcessRequest - */ -class UpdateProcessRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The lineage process to update. - * The process's `name` field is used to identify the process to update. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $process = null; - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set to true and the process is not found, the request inserts it. - * - * Generated from protobuf field bool allow_missing = 3; - */ - protected $allow_missing = false; - - /** - * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $process Required. The lineage process to update. - * - * The process's `name` field is used to identify the process to update. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. Currently not used. The whole message is - * updated. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\UpdateProcessRequest - * - * @experimental - */ - public static function build(\Google\Cloud\DataCatalog\Lineage\V1\Process $process, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setProcess($process) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\DataCatalog\Lineage\V1\Process $process - * Required. The lineage process to update. - * The process's `name` field is used to identify the process to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. Currently not used. The whole message is - * updated. - * @type bool $allow_missing - * If set to true and the process is not found, the request inserts it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The lineage process to update. - * The process's `name` field is used to identify the process to update. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\Process|null - */ - public function getProcess() - { - return $this->process; - } - - public function hasProcess() - { - return isset($this->process); - } - - public function clearProcess() - { - unset($this->process); - } - - /** - * Required. The lineage process to update. - * The process's `name` field is used to identify the process to update. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Process process = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\Process $var - * @return $this - */ - public function setProcess($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\Process::class); - $this->process = $var; - - return $this; - } - - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * If set to true and the process is not found, the request inserts it. - * - * Generated from protobuf field bool allow_missing = 3; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true and the process is not found, the request inserts it. - * - * Generated from protobuf field bool allow_missing = 3; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateRunRequest.php b/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateRunRequest.php deleted file mode 100644 index 72b5866ce820..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/proto/src/Google/Cloud/DataCatalog/Lineage/V1/UpdateRunRequest.php +++ /dev/null @@ -1,159 +0,0 @@ -google.cloud.datacatalog.lineage.v1.UpdateRunRequest - */ -class UpdateRunRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The lineage run to update. - * The run's `name` field is used to identify the run to update. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $run = null; - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $run Required. The lineage run to update. - * - * The run's `name` field is used to identify the run to update. - * - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. Currently not used. The whole message is - * updated. - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\UpdateRunRequest - * - * @experimental - */ - public static function build(\Google\Cloud\DataCatalog\Lineage\V1\Run $run, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setRun($run) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\DataCatalog\Lineage\V1\Run $run - * Required. The lineage run to update. - * The run's `name` field is used to identify the run to update. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. Currently not used. The whole message is - * updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datacatalog\Lineage\V1\Lineage::initOnce(); - parent::__construct($data); - } - - /** - * Required. The lineage run to update. - * The run's `name` field is used to identify the run to update. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataCatalog\Lineage\V1\Run|null - */ - public function getRun() - { - return $this->run; - } - - public function hasRun() - { - return isset($this->run); - } - - public function clearRun() - { - unset($this->run); - } - - /** - * Required. The lineage run to update. - * The run's `name` field is used to identify the run to update. - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * - * Generated from protobuf field .google.cloud.datacatalog.lineage.v1.Run run = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataCatalog\Lineage\V1\Run $var - * @return $this - */ - public function setRun($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataCatalog\Lineage\V1\Run::class); - $this->run = $var; - - return $this; - } - - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. Currently not used. The whole message is - * updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/batch_search_link_processes.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/batch_search_link_processes.php deleted file mode 100644 index fc1b44d52cd3..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/batch_search_link_processes.php +++ /dev/null @@ -1,99 +0,0 @@ -setParent($formattedParent) - ->setLinks($links); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $lineageClient->batchSearchLinkProcesses($request); - - /** @var ProcessLinks $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 = LineageClient::locationName('[PROJECT]', '[LOCATION]'); - $linksElement = '[LINKS]'; - - batch_search_link_processes_sample($formattedParent, $linksElement); -} -// [END datalineage_v1_generated_Lineage_BatchSearchLinkProcesses_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_lineage_event.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_lineage_event.php deleted file mode 100644 index 708598c1828e..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_lineage_event.php +++ /dev/null @@ -1,73 +0,0 @@ -setParent($formattedParent) - ->setLineageEvent($lineageEvent); - - // Call the API and handle any network failures. - try { - /** @var LineageEvent $response */ - $response = $lineageClient->createLineageEvent($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 = LineageClient::runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - - create_lineage_event_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_CreateLineageEvent_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_process.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_process.php deleted file mode 100644 index de3bd8e24140..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_process.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent) - ->setProcess($process); - - // Call the API and handle any network failures. - try { - /** @var Process $response */ - $response = $lineageClient->createProcess($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 = LineageClient::locationName('[PROJECT]', '[LOCATION]'); - - create_process_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_CreateProcess_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_run.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_run.php deleted file mode 100644 index 0a001b418cd4..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/create_run.php +++ /dev/null @@ -1,80 +0,0 @@ -setStartTime($runStartTime) - ->setState($runState); - $request = (new CreateRunRequest()) - ->setParent($formattedParent) - ->setRun($run); - - // Call the API and handle any network failures. - try { - /** @var Run $response */ - $response = $lineageClient->createRun($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 = LineageClient::processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $runState = State::UNKNOWN; - - create_run_sample($formattedParent, $runState); -} -// [END datalineage_v1_generated_Lineage_CreateRun_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_lineage_event.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_lineage_event.php deleted file mode 100644 index a44e3cbec51a..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_lineage_event.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $lineageClient->deleteLineageEvent($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 = LineageClient::lineageEventName( - '[PROJECT]', - '[LOCATION]', - '[PROCESS]', - '[RUN]', - '[LINEAGE_EVENT]' - ); - - delete_lineage_event_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_DeleteLineageEvent_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_process.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_process.php deleted file mode 100644 index 9e847a3a522f..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_process.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $lineageClient->deleteProcess($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 = LineageClient::processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - - delete_process_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_DeleteProcess_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_run.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_run.php deleted file mode 100644 index d54daa9b613f..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/delete_run.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $lineageClient->deleteRun($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 = LineageClient::runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - - delete_run_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_DeleteRun_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_lineage_event.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_lineage_event.php deleted file mode 100644 index af73bcd87409..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_lineage_event.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var LineageEvent $response */ - $response = $lineageClient->getLineageEvent($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 = LineageClient::lineageEventName( - '[PROJECT]', - '[LOCATION]', - '[PROCESS]', - '[RUN]', - '[LINEAGE_EVENT]' - ); - - get_lineage_event_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_GetLineageEvent_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_process.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_process.php deleted file mode 100644 index bbcb7725fbd8..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_process.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Process $response */ - $response = $lineageClient->getProcess($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 = LineageClient::processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - - get_process_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_GetProcess_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_run.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_run.php deleted file mode 100644 index 1c7f828f3747..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/get_run.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Run $response */ - $response = $lineageClient->getRun($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 = LineageClient::runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - - get_run_sample($formattedName); -} -// [END datalineage_v1_generated_Lineage_GetRun_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_lineage_events.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_lineage_events.php deleted file mode 100644 index 6d9d7d95410f..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_lineage_events.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $lineageClient->listLineageEvents($request); - - /** @var LineageEvent $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 = LineageClient::runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - - list_lineage_events_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_ListLineageEvents_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_processes.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_processes.php deleted file mode 100644 index cc374dcf0524..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_processes.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $lineageClient->listProcesses($request); - - /** @var Process $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 = LineageClient::locationName('[PROJECT]', '[LOCATION]'); - - list_processes_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_ListProcesses_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_runs.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_runs.php deleted file mode 100644 index 966835a13579..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/list_runs.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $lineageClient->listRuns($request); - - /** @var Run $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 = LineageClient::processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - - list_runs_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_ListRuns_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/search_links.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/search_links.php deleted file mode 100644 index 84d588e16a42..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/search_links.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $lineageClient->searchLinks($request); - - /** @var Link $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 = LineageClient::locationName('[PROJECT]', '[LOCATION]'); - - search_links_sample($formattedParent); -} -// [END datalineage_v1_generated_Lineage_SearchLinks_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_process.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_process.php deleted file mode 100644 index 706330545719..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_process.php +++ /dev/null @@ -1,59 +0,0 @@ -setProcess($process); - - // Call the API and handle any network failures. - try { - /** @var Process $response */ - $response = $lineageClient->updateProcess($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END datalineage_v1_generated_Lineage_UpdateProcess_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_run.php b/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_run.php deleted file mode 100644 index c8acb38a692d..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/samples/V1/LineageClient/update_run.php +++ /dev/null @@ -1,76 +0,0 @@ -setStartTime($runStartTime) - ->setState($runState); - $request = (new UpdateRunRequest()) - ->setRun($run); - - // Call the API and handle any network failures. - try { - /** @var Run $response */ - $response = $lineageClient->updateRun($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 -{ - $runState = State::UNKNOWN; - - update_run_sample($runState); -} -// [END datalineage_v1_generated_Lineage_UpdateRun_sync] diff --git a/owl-bot-staging/DataCatalogLineage/v1/src/V1/Gapic/LineageGapicClient.php b/owl-bot-staging/DataCatalogLineage/v1/src/V1/Gapic/LineageGapicClient.php deleted file mode 100644 index a3770bcba6ec..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/src/V1/Gapic/LineageGapicClient.php +++ /dev/null @@ -1,1363 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $links = []; - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->batchSearchLinkProcesses($formattedParent, $links); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->batchSearchLinkProcesses($formattedParent, $links); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * 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. - */ -class LineageGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.datacatalog.lineage.v1.Lineage'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'datalineage.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $lineageEventNameTemplate; - - private static $locationNameTemplate; - - private static $processNameTemplate; - - private static $runNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/lineage_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/lineage_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/lineage_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/lineage_rest_client_config.php', - ], - ], - ]; - } - - private static function getLineageEventNameTemplate() - { - if (self::$lineageEventNameTemplate == null) { - self::$lineageEventNameTemplate = new PathTemplate('projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}'); - } - - return self::$lineageEventNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getProcessNameTemplate() - { - if (self::$processNameTemplate == null) { - self::$processNameTemplate = new PathTemplate('projects/{project}/locations/{location}/processes/{process}'); - } - - return self::$processNameTemplate; - } - - private static function getRunNameTemplate() - { - if (self::$runNameTemplate == null) { - self::$runNameTemplate = new PathTemplate('projects/{project}/locations/{location}/processes/{process}/runs/{run}'); - } - - return self::$runNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'lineageEvent' => self::getLineageEventNameTemplate(), - 'location' => self::getLocationNameTemplate(), - 'process' => self::getProcessNameTemplate(), - 'run' => self::getRunNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * lineage_event resource. - * - * @param string $project - * @param string $location - * @param string $process - * @param string $run - * @param string $lineageEvent - * - * @return string The formatted lineage_event resource. - */ - public static function lineageEventName($project, $location, $process, $run, $lineageEvent) - { - return self::getLineageEventNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'process' => $process, - 'run' => $run, - 'lineage_event' => $lineageEvent, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a process - * resource. - * - * @param string $project - * @param string $location - * @param string $process - * - * @return string The formatted process resource. - */ - public static function processName($project, $location, $process) - { - return self::getProcessNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'process' => $process, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a run - * resource. - * - * @param string $project - * @param string $location - * @param string $process - * @param string $run - * - * @return string The formatted run resource. - */ - public static function runName($project, $location, $process, $run) - { - return self::getRunNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'process' => $process, - 'run' => $run, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - lineageEvent: projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event} - * - location: projects/{project}/locations/{location} - * - process: projects/{project}/locations/{location}/processes/{process} - * - run: projects/{project}/locations/{location}/processes/{process}/runs/{run} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'datalineage.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Retrieve information about LineageProcesses associated with specific - * links. LineageProcesses are transformation pipelines that result in data - * flowing from **source** to **target** assets. Links between assets - * represent this operation. - * - * If you have specific link names, you can use this method to - * verify which LineageProcesses contribute to creating those links. - * See the - * [SearchLinks][google.cloud.datacatalog.lineage.v1.Lineage.SearchLinks] - * method for more information on how to retrieve link name. - * - * You can retrieve the LineageProcess information in every project where you - * have the `datalineage.events.get` permission. The project provided in the - * URL is used for Billing and Quota. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->locationName('[PROJECT]', '[LOCATION]'); - * $links = []; - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->batchSearchLinkProcesses($formattedParent, $links); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->batchSearchLinkProcesses($formattedParent, $links); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location you want search in the format `projects/*/locations/*` - * @param string[] $links Required. An array of links to check for their associated LineageProcesses. - * - * The maximum number of items in this array is 100. - * If the request contains more than 100 links, it returns the - * `INVALID_ARGUMENT` error. - * - * Format: `projects/{project}/locations/{location}/links/{link}`. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function batchSearchLinkProcesses($parent, $links, array $optionalArgs = []) - { - $request = new BatchSearchLinkProcessesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setLinks($links); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('BatchSearchLinkProcesses', $optionalArgs, BatchSearchLinkProcessesResponse::class, $request); - } - - /** - * Creates a new lineage event. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - * $lineageEvent = new LineageEvent(); - * $response = $lineageClient->createLineageEvent($formattedParent, $lineageEvent); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the run that should own the lineage event. - * @param LineageEvent $lineageEvent Required. The lineage event to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent - * - * @throws ApiException if the remote call fails - */ - public function createLineageEvent($parent, $lineageEvent, array $optionalArgs = []) - { - $request = new CreateLineageEventRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setLineageEvent($lineageEvent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateLineageEvent', LineageEvent::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new process. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->locationName('[PROJECT]', '[LOCATION]'); - * $process = new Process(); - * $response = $lineageClient->createProcess($formattedParent, $process); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the project and its location that should own the - * process. - * @param Process $process Required. The process to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Process - * - * @throws ApiException if the remote call fails - */ - public function createProcess($parent, $process, array $optionalArgs = []) - { - $request = new CreateProcessRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setProcess($process); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateProcess', Process::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a new run. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - * $run = new Run(); - * $response = $lineageClient->createRun($formattedParent, $run); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the process that should own the run. - * @param Run $run Required. The run to create. - * @param array $optionalArgs { - * Optional. - * - * @type string $requestId - * A unique identifier for this request. Restricted to 36 ASCII characters. - * A random UUID is recommended. This request is idempotent only if a - * `request_id` is provided. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Run - * - * @throws ApiException if the remote call fails - */ - public function createRun($parent, $run, array $optionalArgs = []) - { - $request = new CreateRunRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setRun($run); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['requestId'])) { - $request->setRequestId($optionalArgs['requestId']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateRun', Run::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the lineage event with the specified name. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - * $lineageClient->deleteLineageEvent($formattedName); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the lineage event to delete. - * @param array $optionalArgs { - * Optional. - * - * @type bool $allowMissing - * If set to true and the lineage event is not found, the request - * succeeds but the server doesn't perform any actions. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteLineageEvent($name, array $optionalArgs = []) - { - $request = new DeleteLineageEventRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteLineageEvent', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the process with the specified name. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - * $operationResponse = $lineageClient->deleteProcess($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $lineageClient->deleteProcess($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $lineageClient->resumeOperation($operationName, 'deleteProcess'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the process to delete. - * @param array $optionalArgs { - * Optional. - * - * @type bool $allowMissing - * If set to true and the process is not found, the request - * succeeds but the server doesn't perform any actions. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteProcess($name, array $optionalArgs = []) - { - $request = new DeleteProcessRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteProcess', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes the run with the specified name. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - * $operationResponse = $lineageClient->deleteRun($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $lineageClient->deleteRun($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $lineageClient->resumeOperation($operationName, 'deleteRun'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the run to delete. - * @param array $optionalArgs { - * Optional. - * - * @type bool $allowMissing - * If set to true and the run is not found, the request - * succeeds but the server doesn't perform any actions. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteRun($name, array $optionalArgs = []) - { - $request = new DeleteRunRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteRun', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a specified lineage event. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - * $response = $lineageClient->getLineageEvent($formattedName); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the lineage event to get. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\LineageEvent - * - * @throws ApiException if the remote call fails - */ - public function getLineageEvent($name, array $optionalArgs = []) - { - $request = new GetLineageEventRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetLineageEvent', LineageEvent::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of the specified process. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - * $response = $lineageClient->getProcess($formattedName); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the process to get. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Process - * - * @throws ApiException if the remote call fails - */ - public function getProcess($name, array $optionalArgs = []) - { - $request = new GetProcessRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetProcess', Process::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the details of the specified run. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedName = $lineageClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - * $response = $lineageClient->getRun($formattedName); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the run to get. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Run - * - * @throws ApiException if the remote call fails - */ - public function getRun($name, array $optionalArgs = []) - { - $request = new GetRunRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetRun', Run::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists lineage events in the given project and location. The list order is - * not defined. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->listLineageEvents($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->listLineageEvents($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the run that owns the collection of lineage events to - * get. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listLineageEvents($parent, array $optionalArgs = []) - { - $request = new ListLineageEventsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListLineageEvents', $optionalArgs, ListLineageEventsResponse::class, $request); - } - - /** - * List processes in the given project and location. List order is descending - * by insertion time. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->listProcesses($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->listProcesses($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the project and its location that owns this - * collection of processes. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listProcesses($parent, array $optionalArgs = []) - { - $request = new ListProcessesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListProcesses', $optionalArgs, ListProcessesResponse::class, $request); - } - - /** - * Lists runs in the given project and location. List order is descending by - * `start_time`. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->listRuns($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->listRuns($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of process that owns this collection of runs. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listRuns($parent, array $optionalArgs = []) - { - $request = new ListRunsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListRuns', $optionalArgs, ListRunsResponse::class, $request); - } - - /** - * Retrieve a list of links connected to a specific asset. - * Links represent the data flow between **source** (upstream) - * and **target** (downstream) assets in transformation pipelines. - * Links are stored in the same project as the Lineage Events that create - * them. - * - * You can retrieve links in every project where you have the - * `datalineage.events.get` permission. The project provided in the URL - * is used for Billing and Quota. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $formattedParent = $lineageClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $lineageClient->searchLinks($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $lineageClient->searchLinks($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location you want search in the format `projects/*/locations/*` - * @param array $optionalArgs { - * Optional. - * - * @type EntityReference $source - * Optional. Send asset information in the **source** field to retrieve all - * links that lead from the specified asset to downstream assets. - * @type EntityReference $target - * Optional. Send asset information in the **target** field to retrieve all - * links that lead from upstream assets to the specified asset. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function searchLinks($parent, array $optionalArgs = []) - { - $request = new SearchLinksRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['source'])) { - $request->setSource($optionalArgs['source']); - } - - if (isset($optionalArgs['target'])) { - $request->setTarget($optionalArgs['target']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('SearchLinks', $optionalArgs, SearchLinksResponse::class, $request); - } - - /** - * Updates a process. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $process = new Process(); - * $response = $lineageClient->updateProcess($process); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param Process $process Required. The lineage process to update. - * - * The process's `name` field is used to identify the process to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. Currently not used. The whole message is - * updated. - * @type bool $allowMissing - * If set to true and the process is not found, the request inserts it. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Process - * - * @throws ApiException if the remote call fails - */ - public function updateProcess($process, array $optionalArgs = []) - { - $request = new UpdateProcessRequest(); - $requestParamHeaders = []; - $request->setProcess($process); - $requestParamHeaders['process.name'] = $process->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['allowMissing'])) { - $request->setAllowMissing($optionalArgs['allowMissing']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateProcess', Process::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a run. - * - * Sample code: - * ``` - * $lineageClient = new LineageClient(); - * try { - * $run = new Run(); - * $response = $lineageClient->updateRun($run); - * } finally { - * $lineageClient->close(); - * } - * ``` - * - * @param Run $run Required. The lineage run to update. - * - * The run's `name` field is used to identify the run to update. - * - * Format: - * `projects/{project}/locations/{location}/processes/{process}/runs/{run}`. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. Currently not used. The whole message is - * updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataCatalog\Lineage\V1\Run - * - * @throws ApiException if the remote call fails - */ - public function updateRun($run, array $optionalArgs = []) - { - $request = new UpdateRunRequest(); - $requestParamHeaders = []; - $request->setRun($run); - $requestParamHeaders['run.name'] = $run->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateRun', Run::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/DataCatalogLineage/v1/src/V1/LineageClient.php b/owl-bot-staging/DataCatalogLineage/v1/src/V1/LineageClient.php deleted file mode 100644 index f7aee18948eb..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/src/V1/LineageClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.cloud.datacatalog.lineage.v1.Lineage' => [ - 'DeleteProcess' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRun' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\DataCatalog\Lineage\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'BatchSearchLinkProcesses' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getProcessLinks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\BatchSearchLinkProcessesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateLineageEvent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateProcess' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRun' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteLineageEvent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetLineageEvent' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\LineageEvent', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetProcess' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetRun' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListLineageEvents' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLineageEvents', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListLineageEventsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListProcesses' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getProcesses', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListProcessesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListRuns' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRuns', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\ListRunsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'SearchLinks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLinks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\SearchLinksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateProcess' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Process', - 'headerParams' => [ - [ - 'keyName' => 'process.name', - 'fieldAccessors' => [ - 'getProcess', - 'getName', - ], - ], - ], - ], - 'UpdateRun' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataCatalog\Lineage\V1\Run', - 'headerParams' => [ - [ - 'keyName' => 'run.name', - 'fieldAccessors' => [ - 'getRun', - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'lineageEvent' => 'projects/{project}/locations/{location}/processes/{process}/runs/{run}/lineageEvents/{lineage_event}', - 'location' => 'projects/{project}/locations/{location}', - 'process' => 'projects/{project}/locations/{location}/processes/{process}', - 'run' => 'projects/{project}/locations/{location}/processes/{process}/runs/{run}', - ], - ], - ], -]; diff --git a/owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_rest_client_config.php b/owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_rest_client_config.php deleted file mode 100644 index 39ff25c49e3a..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/src/V1/resources/lineage_rest_client_config.php +++ /dev/null @@ -1,240 +0,0 @@ - [ - 'google.cloud.datacatalog.lineage.v1.Lineage' => [ - 'BatchSearchLinkProcesses' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}:batchSearchLinkProcesses', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateLineageEvent' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/processes/*/runs/*}/lineageEvents', - 'body' => 'lineage_event', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateProcess' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/processes', - 'body' => 'process', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRun' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/processes/*}/runs', - 'body' => 'run', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteLineageEvent' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*/runs/*/lineageEvents/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteProcess' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRun' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*/runs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetLineageEvent' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*/runs/*/lineageEvents/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetProcess' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetRun' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/processes/*/runs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLineageEvents' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/processes/*/runs/*}/lineageEvents', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListProcesses' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/processes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListRuns' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/processes/*}/runs', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SearchLinks' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}:searchLinks', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateProcess' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{process.name=projects/*/locations/*/processes/*}', - 'body' => 'process', - 'placeholders' => [ - 'process.name' => [ - 'getters' => [ - 'getProcess', - 'getName', - ], - ], - ], - ], - 'UpdateRun' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{run.name=projects/*/locations/*/processes/*/runs/*}', - 'body' => 'run', - 'placeholders' => [ - 'run.name' => [ - 'getters' => [ - 'getRun', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/LineageClientTest.php b/owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/LineageClientTest.php deleted file mode 100644 index 575205c031dc..000000000000 --- a/owl-bot-staging/DataCatalogLineage/v1/tests/Unit/V1/LineageClientTest.php +++ /dev/null @@ -1,1232 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return LineageClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new LineageClient($options); - } - - /** @test */ - public function batchSearchLinkProcessesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $processLinksElement = new ProcessLinks(); - $processLinks = [ - $processLinksElement, - ]; - $expectedResponse = new BatchSearchLinkProcessesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setProcessLinks($processLinks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $links = []; - $response = $gapicClient->batchSearchLinkProcesses($formattedParent, $links); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getProcessLinks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/BatchSearchLinkProcesses', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getLinks(); - $this->assertProtobufEquals($links, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchSearchLinkProcessesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $links = []; - try { - $gapicClient->batchSearchLinkProcesses($formattedParent, $links); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createLineageEventTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $expectedResponse = new LineageEvent(); - $expectedResponse->setName($name); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $lineageEvent = new LineageEvent(); - $response = $gapicClient->createLineageEvent($formattedParent, $lineageEvent); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/CreateLineageEvent', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getLineageEvent(); - $this->assertProtobufEquals($lineageEvent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createLineageEventExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $lineageEvent = new LineageEvent(); - try { - $gapicClient->createLineageEvent($formattedParent, $lineageEvent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createProcessTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Process(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $process = new Process(); - $response = $gapicClient->createProcess($formattedParent, $process); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/CreateProcess', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getProcess(); - $this->assertProtobufEquals($process, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createProcessExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $process = new Process(); - try { - $gapicClient->createProcess($formattedParent, $process); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createRunTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Run(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $run = new Run(); - $runStartTime = new Timestamp(); - $run->setStartTime($runStartTime); - $runState = State::UNKNOWN; - $run->setState($runState); - $response = $gapicClient->createRun($formattedParent, $run); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/CreateRun', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRun(); - $this->assertProtobufEquals($run, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createRunExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $run = new Run(); - $runStartTime = new Timestamp(); - $run->setStartTime($runStartTime); - $runState = State::UNKNOWN; - $run->setState($runState); - try { - $gapicClient->createRun($formattedParent, $run); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteLineageEventTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - $gapicClient->deleteLineageEvent($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteLineageEvent', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteLineageEventExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - try { - $gapicClient->deleteLineageEvent($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteProcessTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteProcessTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteProcessTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $response = $gapicClient->deleteProcess($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteProcess', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteProcessTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteProcessExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteProcessTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $response = $gapicClient->deleteProcess($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteProcessTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteRunTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteRunTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteRunTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $response = $gapicClient->deleteRun($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/DeleteRun', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRunTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteRunExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteRunTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $response = $gapicClient->deleteRun($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRunTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getLineageEventTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new LineageEvent(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - $response = $gapicClient->getLineageEvent($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/GetLineageEvent', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLineageEventExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->lineageEventName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]', '[LINEAGE_EVENT]'); - try { - $gapicClient->getLineageEvent($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getProcessTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Process(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $response = $gapicClient->getProcess($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/GetProcess', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getProcessExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - try { - $gapicClient->getProcess($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRunTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Run(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $response = $gapicClient->getRun($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/GetRun', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRunExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - try { - $gapicClient->getRun($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLineageEventsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $lineageEventsElement = new LineageEvent(); - $lineageEvents = [ - $lineageEventsElement, - ]; - $expectedResponse = new ListLineageEventsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLineageEvents($lineageEvents); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - $response = $gapicClient->listLineageEvents($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLineageEvents()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/ListLineageEvents', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLineageEventsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->runName('[PROJECT]', '[LOCATION]', '[PROCESS]', '[RUN]'); - try { - $gapicClient->listLineageEvents($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listProcessesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $processesElement = new Process(); - $processes = [ - $processesElement, - ]; - $expectedResponse = new ListProcessesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setProcesses($processes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listProcesses($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getProcesses()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/ListProcesses', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listProcessesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listProcesses($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRunsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $runsElement = new Run(); - $runs = [ - $runsElement, - ]; - $expectedResponse = new ListRunsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRuns($runs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - $response = $gapicClient->listRuns($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRuns()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/ListRuns', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRunsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->processName('[PROJECT]', '[LOCATION]', '[PROCESS]'); - try { - $gapicClient->listRuns($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function searchLinksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $linksElement = new Link(); - $links = [ - $linksElement, - ]; - $expectedResponse = new SearchLinksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLinks($links); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->searchLinks($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLinks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/SearchLinks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function searchLinksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->searchLinks($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateProcessTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Process(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $process = new Process(); - $response = $gapicClient->updateProcess($process); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/UpdateProcess', $actualFuncCall); - $actualValue = $actualRequestObject->getProcess(); - $this->assertProtobufEquals($process, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateProcessExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $process = new Process(); - try { - $gapicClient->updateProcess($process); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateRunTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $expectedResponse = new Run(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $run = new Run(); - $runStartTime = new Timestamp(); - $run->setStartTime($runStartTime); - $runState = State::UNKNOWN; - $run->setState($runState); - $response = $gapicClient->updateRun($run); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datacatalog.lineage.v1.Lineage/UpdateRun', $actualFuncCall); - $actualValue = $actualRequestObject->getRun(); - $this->assertProtobufEquals($run, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateRunExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $run = new Run(); - $runStartTime = new Timestamp(); - $run->setStartTime($runStartTime); - $runState = State::UNKNOWN; - $run->setState($runState); - try { - $gapicClient->updateRun($run); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/DataFusion/v1/proto/src/GPBMetadata/Google/Cloud/Datafusion/V1/Datafusion.php b/owl-bot-staging/DataFusion/v1/proto/src/GPBMetadata/Google/Cloud/Datafusion/V1/Datafusion.php deleted file mode 100644 index 03131d9ee83191982d1a150e8426c77d69574c38..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6980 zcmcgxOK%&=5e}&*ixNfkS~f*n-dWm-Wvxxd+=p%2@@7O*G9j6wNlFU`L?**wQ<`Wr zGnpC6%Qch)0rCrSORhO3*8uqk3E&`?%^`q+02?Hyz2~y0RQEhcN;FMxg6N`QcU5&& zbya=U-48!84^6lxY*C$BvO`-!vnx1+6Ah4OA) zC>Bcf_mI^#I+j9n!hvBNXf&f}MyHi&$&TFa*s7stPVV&mN^`jYx_nG+Q&y<3RoQq# z9hosSwz!B!o{4A_0uhbV9ofNu*Hv3mb=6U2P5m6L zSr^)}W>aK8PuuS3ih~*ojA2(-=;}?umC0zYn+96HF8E4Sm_yJRjgszAOP94qf!d0t znvP*rkTjP&pibaMHnMutTb7Aa+rp}=V=i}2$#uc8I<$XvL9nRPvGfOAZzkY0_-YJs znP{pFQP&OT1w*%Uxt>iu5wBy+Ybw>9x8vDVsn*({hw_PPSZ~K#rC!L4t>liOA6Ok- zSM`I&uE_%R?Tifej%)oywvWcwIN+_T7_yFhY!2t;@pAi->P3gxY6ZctiHWlsY#-aq z8}PFXy#E#%Ly|6Wnx|K~mtN_UJIPC)AlXzg{n%c*X_kDqZ=%gMOlo>N<`FFS5m?@~ zcvIKBDXr)Gj1lQT!%!X5c55denwOEZI7a?}yeoA`hxJfOK^%5+!Xj|@R zj^xdA=2?;iBA>{rCO0)IwW*A`M(xCeFoElR43kdRq=`vfCYD`IyN(#<`Lwrwx{maz zCoswWlM4{9KdTg_y>hKm%$GJx#X|gBBo1?Yv{EhZmx`apLu3V(`N&qWT&#*alDIFH zcEpX+PO1JZ9!~u!3{g>0C>C8AYYce`ak=+X;wmx+#jV3t?egxY zWt3Bag}l|pLcLA9UXZQB{1NR+7Da5MSo+;~+4#=a;x%}W=h)G)?YRTf%1$HxWdb3o zFXmykq@(YUmE40#24|j#wJ*hquf^+->dR3#f&w`K=Q|K>c_4yO?8Y^D=!M?|-`ks` z_QV&&<8Nc)OEFARkfb_~YSd0SYFR1w;CbUwKXx#XGDm3DJm&EX%jOz9?gzab}-Ao2h*5*RI?Mam~_$XcgM1GhqDxQ z$Lf*|m@!Na1c?Y2ac3+MyDpC_<3orl7G^({SXoK{w<77w@oQE(DE-XG69lf%dHlPpCSe{o0T)FWvgHGsm`6DgcWwpZHnmPvg-TR! znFgXzBG#LpgUQbgohBC85G$~LF^uzptFYj6V}&s~$h^pzrxGD%?**7^skW)fU5N)e z;arbku~$NUf$#90xHif*uV#{En8S?d>3e}M$sK$N;6SmZW=A=qPGYGyv5q{w8fYgj z^5q&gMy=OZqsY5J%nzlr#$M_za1|CE%njX3I2FylKT7wY;&^52DdL%Gv-ECZ?UHRQ8Y}36 zSoVWaQi5nIc)V54%0nl48>0PL6@>{@(Sy%lF z7=ft`u~zc%pjfUKtCec0#_(VsB8B39ac8$utYQuSedrBffb~CLEsFJ0c?;11U|P)A zOZ!X`es3bOB1%kflt6gmRFiCty~5Oi+i6-ih6#xJLBc9J-)C0; z!r1N4`ZGKh$BdrTQ&=isZ|=~uT7GlOe}R_o@y6n;%m;l+vYvlTC0z?MLA%1vW!&~? z_I#5QoQ+dexQJ(TN4EZlyZY}iECxq+|H6l$YW@9}Yub6$g8qx#f>~^E+-{9+;xI#c z)L2!}3cQ!`stoo)82U}G#^AY+Ij600rz=Hu+^7`7?&t&_Y4(jZ$+ci`mtxBo&pa1n=zYM3zEp|)z!o`^N z0K?Y$uxsr!<5#U$qK8K0cOjT(s`=?+laa@W0a9Q4k*9_;9G=!6aji4t_BdMm#l29;y|`fD88*8{Abl7ECCHduAZNY4z?`YNvYCiUGKrGpqx zopQ(BPraSvazTN9C0=%8$-iY&u;s#GZemJ%e~L+MYq$G41&&w`U{!F%Nd%@9A+3 z>)*T!KKCu}_{{L=jl1^85G;__=Rg}xBehmK>~xlHEy^XHyciM(^yzz%HT*X_d5uT`o zzW>N|kbi}Vmskfz-*Zd`R~UGoF`Ey1Dw@sThLcgoogle.cloud.datafusion.v1.Accelerator - */ -class Accelerator extends \Google\Protobuf\Internal\Message -{ - /** - * The type of an accelator for a CDF instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.AcceleratorType accelerator_type = 1; - */ - protected $accelerator_type = 0; - /** - * The state of the accelerator - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.State state = 2; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $accelerator_type - * The type of an accelator for a CDF instance. - * @type int $state - * The state of the accelerator - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * The type of an accelator for a CDF instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.AcceleratorType accelerator_type = 1; - * @return int - */ - public function getAcceleratorType() - { - return $this->accelerator_type; - } - - /** - * The type of an accelator for a CDF instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.AcceleratorType accelerator_type = 1; - * @param int $var - * @return $this - */ - public function setAcceleratorType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataFusion\V1\Accelerator\AcceleratorType::class); - $this->accelerator_type = $var; - - return $this; - } - - /** - * The state of the accelerator - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.State state = 2; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of the accelerator - * - * Generated from protobuf field .google.cloud.datafusion.v1.Accelerator.State state = 2; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataFusion\V1\Accelerator\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/AcceleratorType.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/AcceleratorType.php deleted file mode 100644 index aa79f79a9375..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/AcceleratorType.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.datafusion.v1.Accelerator.AcceleratorType - */ -class AcceleratorType -{ - /** - * Default value, if unspecified. - * - * Generated from protobuf enum ACCELERATOR_TYPE_UNSPECIFIED = 0; - */ - const ACCELERATOR_TYPE_UNSPECIFIED = 0; - /** - * Change Data Capture accelerator for CDF. - * - * Generated from protobuf enum CDC = 1; - */ - const CDC = 1; - /** - * Cloud Healthcare accelerator for CDF. This accelerator is to enable Cloud - * Healthcare specific CDF plugins developed by Healthcare team. - * - * Generated from protobuf enum HEALTHCARE = 2; - */ - const HEALTHCARE = 2; - /** - * Contact Center AI Insights - * This accelerator is used to enable import and export pipelines - * custom built to streamline CCAI Insights processing. - * - * Generated from protobuf enum CCAI_INSIGHTS = 3; - */ - const CCAI_INSIGHTS = 3; - - private static $valueToName = [ - self::ACCELERATOR_TYPE_UNSPECIFIED => 'ACCELERATOR_TYPE_UNSPECIFIED', - self::CDC => 'CDC', - self::HEALTHCARE => 'HEALTHCARE', - self::CCAI_INSIGHTS => 'CCAI_INSIGHTS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AcceleratorType::class, \Google\Cloud\DataFusion\V1\Accelerator_AcceleratorType::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/State.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/State.php deleted file mode 100644 index 761acd3e719e..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator/State.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.datafusion.v1.Accelerator.State - */ -class State -{ - /** - * Default value, do not use - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Indicates that the accelerator is enabled and available to use - * - * Generated from protobuf enum ENABLED = 1; - */ - const ENABLED = 1; - /** - * Indicates that the accelerator is disabled and not available to use - * - * Generated from protobuf enum DISABLED = 2; - */ - const DISABLED = 2; - /** - * Indicates that accelerator state is currently unknown. - * Requests for enable, disable could be retried while in this state - * - * Generated from protobuf enum UNKNOWN = 3; - */ - const UNKNOWN = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ENABLED => 'ENABLED', - self::DISABLED => 'DISABLED', - self::UNKNOWN => 'UNKNOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\DataFusion\V1\Accelerator_State::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator_AcceleratorType.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator_AcceleratorType.php deleted file mode 100644 index 8a3969f75af6..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Accelerator_AcceleratorType.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.datafusion.v1.CreateInstanceRequest - */ -class CreateInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The instance's project and location in the format - * projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The name of the instance to create. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance_id = ''; - /** - * An instance resource. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 3; - */ - protected $instance = null; - - /** - * @param string $parent Required. The instance's project and location in the format - * projects/{project}/locations/{location}. Please see - * {@see DataFusionClient::locationName()} for help formatting this field. - * @param \Google\Cloud\DataFusion\V1\Instance $instance An instance resource. - * @param string $instanceId Required. The name of the instance to create. - * - * @return \Google\Cloud\DataFusion\V1\CreateInstanceRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\DataFusion\V1\Instance $instance, string $instanceId): self - { - return (new self()) - ->setParent($parent) - ->setInstance($instance) - ->setInstanceId($instanceId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The instance's project and location in the format - * projects/{project}/locations/{location}. - * @type string $instance_id - * Required. The name of the instance to create. - * @type \Google\Cloud\DataFusion\V1\Instance $instance - * An instance resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The instance's project and location in the format - * projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The instance's project and location in the format - * projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The name of the instance to create. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getInstanceId() - { - return $this->instance_id; - } - - /** - * Required. The name of the instance to create. - * - * Generated from protobuf field string instance_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setInstanceId($var) - { - GPBUtil::checkString($var, True); - $this->instance_id = $var; - - return $this; - } - - /** - * An instance resource. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 3; - * @return \Google\Cloud\DataFusion\V1\Instance|null - */ - public function getInstance() - { - return $this->instance; - } - - public function hasInstance() - { - return isset($this->instance); - } - - public function clearInstance() - { - unset($this->instance); - } - - /** - * An instance resource. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 3; - * @param \Google\Cloud\DataFusion\V1\Instance $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataFusion\V1\Instance::class); - $this->instance = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/CryptoKeyConfig.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/CryptoKeyConfig.php deleted file mode 100644 index 8b36d565ce86..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/CryptoKeyConfig.php +++ /dev/null @@ -1,76 +0,0 @@ -google.cloud.datafusion.v1.CryptoKeyConfig - */ -class CryptoKeyConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the key which is used to encrypt/decrypt customer data. For key - * in Cloud KMS, the key should be in the format of - * `projects/*/locations/*/keyRings/*/cryptoKeys/*`. - * - * Generated from protobuf field string key_reference = 1 [(.google.api.resource_reference) = { - */ - protected $key_reference = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_reference - * The name of the key which is used to encrypt/decrypt customer data. For key - * in Cloud KMS, the key should be in the format of - * `projects/*/locations/*/keyRings/*/cryptoKeys/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * The name of the key which is used to encrypt/decrypt customer data. For key - * in Cloud KMS, the key should be in the format of - * `projects/*/locations/*/keyRings/*/cryptoKeys/*`. - * - * Generated from protobuf field string key_reference = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getKeyReference() - { - return $this->key_reference; - } - - /** - * The name of the key which is used to encrypt/decrypt customer data. For key - * in Cloud KMS, the key should be in the format of - * `projects/*/locations/*/keyRings/*/cryptoKeys/*`. - * - * Generated from protobuf field string key_reference = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKeyReference($var) - { - GPBUtil::checkString($var, True); - $this->key_reference = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DataFusionGrpcClient.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DataFusionGrpcClient.php deleted file mode 100644 index 2afdb990f744..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DataFusionGrpcClient.php +++ /dev/null @@ -1,144 +0,0 @@ -_simpleRequest('/google.cloud.datafusion.v1.DataFusion/ListAvailableVersions', - $argument, - ['\Google\Cloud\DataFusion\V1\ListAvailableVersionsResponse', 'decode'], - $metadata, $options); - } - - /** - * Lists Data Fusion instances in the specified project and location. - * @param \Google\Cloud\DataFusion\V1\ListInstancesRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function ListInstances(\Google\Cloud\DataFusion\V1\ListInstancesRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/ListInstances', - $argument, - ['\Google\Cloud\DataFusion\V1\ListInstancesResponse', 'decode'], - $metadata, $options); - } - - /** - * Gets details of a single Data Fusion instance. - * @param \Google\Cloud\DataFusion\V1\GetInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function GetInstance(\Google\Cloud\DataFusion\V1\GetInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/GetInstance', - $argument, - ['\Google\Cloud\DataFusion\V1\Instance', 'decode'], - $metadata, $options); - } - - /** - * Creates a new Data Fusion instance in the specified project and location. - * @param \Google\Cloud\DataFusion\V1\CreateInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function CreateInstance(\Google\Cloud\DataFusion\V1\CreateInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/CreateInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Deletes a single Date Fusion instance. - * @param \Google\Cloud\DataFusion\V1\DeleteInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function DeleteInstance(\Google\Cloud\DataFusion\V1\DeleteInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/DeleteInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Updates a single Data Fusion instance. - * @param \Google\Cloud\DataFusion\V1\UpdateInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function UpdateInstance(\Google\Cloud\DataFusion\V1\UpdateInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/UpdateInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - - /** - * Restart a single Data Fusion instance. - * At the end of an operation instance is fully restarted. - * @param \Google\Cloud\DataFusion\V1\RestartInstanceRequest $argument input argument - * @param array $metadata metadata - * @param array $options call options - * @return \Grpc\UnaryCall - */ - public function RestartInstance(\Google\Cloud\DataFusion\V1\RestartInstanceRequest $argument, - $metadata = [], $options = []) { - return $this->_simpleRequest('/google.cloud.datafusion.v1.DataFusion/RestartInstance', - $argument, - ['\Google\LongRunning\Operation', 'decode'], - $metadata, $options); - } - -} diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DeleteInstanceRequest.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DeleteInstanceRequest.php deleted file mode 100644 index 323b13f57fd0..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/DeleteInstanceRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.datafusion.v1.DeleteInstanceRequest - */ -class DeleteInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * Please see {@see DataFusionClient::instanceName()} for help formatting this field. - * - * @return \Google\Cloud\DataFusion\V1\DeleteInstanceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/GetInstanceRequest.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/GetInstanceRequest.php deleted file mode 100644 index 834a6a4a0037..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/GetInstanceRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.datafusion.v1.GetInstanceRequest - */ -class GetInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance}. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance.php deleted file mode 100644 index 9cf4529e3785..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance.php +++ /dev/null @@ -1,1086 +0,0 @@ -google.cloud.datafusion.v1.Instance - */ -class Instance extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The name of this instance is in the form of - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * A description of this instance. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * Required. Instance type. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Option to enable Stackdriver Logging. - * - * Generated from protobuf field bool enable_stackdriver_logging = 4; - */ - protected $enable_stackdriver_logging = false; - /** - * Option to enable Stackdriver Monitoring. - * - * Generated from protobuf field bool enable_stackdriver_monitoring = 5; - */ - protected $enable_stackdriver_monitoring = false; - /** - * Specifies whether the Data Fusion instance should be private. If set to - * true, all Data Fusion nodes will have private IP addresses and will not be - * able to access the public internet. - * - * Generated from protobuf field bool private_instance = 6; - */ - protected $private_instance = false; - /** - * Network configuration options. These are required when a private Data - * Fusion instance is to be created. - * - * Generated from protobuf field .google.cloud.datafusion.v1.NetworkConfig network_config = 7; - */ - protected $network_config = null; - /** - * The resource labels for instance to use to annotate any related underlying - * resources such as Compute Engine VMs. The character '=' is not allowed to - * be used within the labels. - * - * Generated from protobuf field map labels = 8; - */ - private $labels; - /** - * Map of additional options used to configure the behavior of - * Data Fusion instance. - * - * Generated from protobuf field map options = 9; - */ - private $options; - /** - * Output only. The time the instance was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time the instance was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The current state of this Data Fusion instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.State state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Additional information about the current state of this Data - * Fusion instance if available. - * - * Generated from protobuf field string state_message = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state_message = ''; - /** - * Output only. Endpoint on which the Data Fusion UI is accessible. - * - * Generated from protobuf field string service_endpoint = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $service_endpoint = ''; - /** - * Name of the zone in which the Data Fusion instance will be created. Only - * DEVELOPER instances use this field. - * - * Generated from protobuf field string zone = 15; - */ - protected $zone = ''; - /** - * Current version of the Data Fusion. Only specifiable in Update. - * - * Generated from protobuf field string version = 16; - */ - protected $version = ''; - /** - * Output only. Deprecated. Use tenant_project_id instead to extract the tenant project ID. - * - * Generated from protobuf field string service_account = 17 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @deprecated - */ - protected $service_account = ''; - /** - * Display name for an instance. - * - * Generated from protobuf field string display_name = 18; - */ - protected $display_name = ''; - /** - * Available versions that the instance can be upgraded to using - * UpdateInstanceRequest. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_version = 19; - */ - private $available_version; - /** - * Output only. Endpoint on which the REST APIs is accessible. - * - * Generated from protobuf field string api_endpoint = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $api_endpoint = ''; - /** - * Output only. Cloud Storage bucket generated by Data Fusion in the customer project. - * - * Generated from protobuf field string gcs_bucket = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $gcs_bucket = ''; - /** - * List of accelerators enabled for this CDF instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Accelerator accelerators = 22; - */ - private $accelerators; - /** - * Output only. P4 service account for the customer project. - * - * Generated from protobuf field string p4_service_account = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $p4_service_account = ''; - /** - * Output only. The name of the tenant project. - * - * Generated from protobuf field string tenant_project_id = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $tenant_project_id = ''; - /** - * User-managed service account to set on Dataproc when Cloud Data Fusion - * creates Dataproc to run data processing pipelines. - * This allows users to have fine-grained access control on Dataproc's - * accesses to cloud resources. - * - * Generated from protobuf field string dataproc_service_account = 25; - */ - protected $dataproc_service_account = ''; - /** - * Option to enable granular role-based access control. - * - * Generated from protobuf field bool enable_rbac = 27; - */ - protected $enable_rbac = false; - /** - * The crypto key configuration. This field is used by the Customer-Managed - * Encryption Keys (CMEK) feature. - * - * Generated from protobuf field .google.cloud.datafusion.v1.CryptoKeyConfig crypto_key_config = 28; - */ - protected $crypto_key_config = null; - /** - * Output only. If the instance state is DISABLED, the reason for disabling the instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance.DisabledReason disabled_reason = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $disabled_reason; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The name of this instance is in the form of - * projects/{project}/locations/{location}/instances/{instance}. - * @type string $description - * A description of this instance. - * @type int $type - * Required. Instance type. - * @type bool $enable_stackdriver_logging - * Option to enable Stackdriver Logging. - * @type bool $enable_stackdriver_monitoring - * Option to enable Stackdriver Monitoring. - * @type bool $private_instance - * Specifies whether the Data Fusion instance should be private. If set to - * true, all Data Fusion nodes will have private IP addresses and will not be - * able to access the public internet. - * @type \Google\Cloud\DataFusion\V1\NetworkConfig $network_config - * Network configuration options. These are required when a private Data - * Fusion instance is to be created. - * @type array|\Google\Protobuf\Internal\MapField $labels - * The resource labels for instance to use to annotate any related underlying - * resources such as Compute Engine VMs. The character '=' is not allowed to - * be used within the labels. - * @type array|\Google\Protobuf\Internal\MapField $options - * Map of additional options used to configure the behavior of - * Data Fusion instance. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time the instance was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time the instance was last updated. - * @type int $state - * Output only. The current state of this Data Fusion instance. - * @type string $state_message - * Output only. Additional information about the current state of this Data - * Fusion instance if available. - * @type string $service_endpoint - * Output only. Endpoint on which the Data Fusion UI is accessible. - * @type string $zone - * Name of the zone in which the Data Fusion instance will be created. Only - * DEVELOPER instances use this field. - * @type string $version - * Current version of the Data Fusion. Only specifiable in Update. - * @type string $service_account - * Output only. Deprecated. Use tenant_project_id instead to extract the tenant project ID. - * @type string $display_name - * Display name for an instance. - * @type array<\Google\Cloud\DataFusion\V1\Version>|\Google\Protobuf\Internal\RepeatedField $available_version - * Available versions that the instance can be upgraded to using - * UpdateInstanceRequest. - * @type string $api_endpoint - * Output only. Endpoint on which the REST APIs is accessible. - * @type string $gcs_bucket - * Output only. Cloud Storage bucket generated by Data Fusion in the customer project. - * @type array<\Google\Cloud\DataFusion\V1\Accelerator>|\Google\Protobuf\Internal\RepeatedField $accelerators - * List of accelerators enabled for this CDF instance. - * @type string $p4_service_account - * Output only. P4 service account for the customer project. - * @type string $tenant_project_id - * Output only. The name of the tenant project. - * @type string $dataproc_service_account - * User-managed service account to set on Dataproc when Cloud Data Fusion - * creates Dataproc to run data processing pipelines. - * This allows users to have fine-grained access control on Dataproc's - * accesses to cloud resources. - * @type bool $enable_rbac - * Option to enable granular role-based access control. - * @type \Google\Cloud\DataFusion\V1\CryptoKeyConfig $crypto_key_config - * The crypto key configuration. This field is used by the Customer-Managed - * Encryption Keys (CMEK) feature. - * @type array|\Google\Protobuf\Internal\RepeatedField $disabled_reason - * Output only. If the instance state is DISABLED, the reason for disabling the instance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The name of this instance is in the form of - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The name of this instance is in the form of - * projects/{project}/locations/{location}/instances/{instance}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A description of this instance. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A description of this instance. - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. Instance type. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. Instance type. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataFusion\V1\Instance\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Option to enable Stackdriver Logging. - * - * Generated from protobuf field bool enable_stackdriver_logging = 4; - * @return bool - */ - public function getEnableStackdriverLogging() - { - return $this->enable_stackdriver_logging; - } - - /** - * Option to enable Stackdriver Logging. - * - * Generated from protobuf field bool enable_stackdriver_logging = 4; - * @param bool $var - * @return $this - */ - public function setEnableStackdriverLogging($var) - { - GPBUtil::checkBool($var); - $this->enable_stackdriver_logging = $var; - - return $this; - } - - /** - * Option to enable Stackdriver Monitoring. - * - * Generated from protobuf field bool enable_stackdriver_monitoring = 5; - * @return bool - */ - public function getEnableStackdriverMonitoring() - { - return $this->enable_stackdriver_monitoring; - } - - /** - * Option to enable Stackdriver Monitoring. - * - * Generated from protobuf field bool enable_stackdriver_monitoring = 5; - * @param bool $var - * @return $this - */ - public function setEnableStackdriverMonitoring($var) - { - GPBUtil::checkBool($var); - $this->enable_stackdriver_monitoring = $var; - - return $this; - } - - /** - * Specifies whether the Data Fusion instance should be private. If set to - * true, all Data Fusion nodes will have private IP addresses and will not be - * able to access the public internet. - * - * Generated from protobuf field bool private_instance = 6; - * @return bool - */ - public function getPrivateInstance() - { - return $this->private_instance; - } - - /** - * Specifies whether the Data Fusion instance should be private. If set to - * true, all Data Fusion nodes will have private IP addresses and will not be - * able to access the public internet. - * - * Generated from protobuf field bool private_instance = 6; - * @param bool $var - * @return $this - */ - public function setPrivateInstance($var) - { - GPBUtil::checkBool($var); - $this->private_instance = $var; - - return $this; - } - - /** - * Network configuration options. These are required when a private Data - * Fusion instance is to be created. - * - * Generated from protobuf field .google.cloud.datafusion.v1.NetworkConfig network_config = 7; - * @return \Google\Cloud\DataFusion\V1\NetworkConfig|null - */ - public function getNetworkConfig() - { - return $this->network_config; - } - - public function hasNetworkConfig() - { - return isset($this->network_config); - } - - public function clearNetworkConfig() - { - unset($this->network_config); - } - - /** - * Network configuration options. These are required when a private Data - * Fusion instance is to be created. - * - * Generated from protobuf field .google.cloud.datafusion.v1.NetworkConfig network_config = 7; - * @param \Google\Cloud\DataFusion\V1\NetworkConfig $var - * @return $this - */ - public function setNetworkConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataFusion\V1\NetworkConfig::class); - $this->network_config = $var; - - return $this; - } - - /** - * The resource labels for instance to use to annotate any related underlying - * resources such as Compute Engine VMs. The character '=' is not allowed to - * be used within the labels. - * - * Generated from protobuf field map labels = 8; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * The resource labels for instance to use to annotate any related underlying - * resources such as Compute Engine VMs. The character '=' is not allowed to - * be used within the labels. - * - * Generated from protobuf field map labels = 8; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Map of additional options used to configure the behavior of - * Data Fusion instance. - * - * Generated from protobuf field map options = 9; - * @return \Google\Protobuf\Internal\MapField - */ - public function getOptions() - { - return $this->options; - } - - /** - * Map of additional options used to configure the behavior of - * Data Fusion instance. - * - * Generated from protobuf field map options = 9; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setOptions($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->options = $arr; - - return $this; - } - - /** - * Output only. The time the instance was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time the instance was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The time the instance was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The time the instance was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The current state of this Data Fusion instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.State state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The current state of this Data Fusion instance. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance.State state = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataFusion\V1\Instance\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Additional information about the current state of this Data - * Fusion instance if available. - * - * Generated from protobuf field string state_message = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStateMessage() - { - return $this->state_message; - } - - /** - * Output only. Additional information about the current state of this Data - * Fusion instance if available. - * - * Generated from protobuf field string state_message = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStateMessage($var) - { - GPBUtil::checkString($var, True); - $this->state_message = $var; - - return $this; - } - - /** - * Output only. Endpoint on which the Data Fusion UI is accessible. - * - * Generated from protobuf field string service_endpoint = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getServiceEndpoint() - { - return $this->service_endpoint; - } - - /** - * Output only. Endpoint on which the Data Fusion UI is accessible. - * - * Generated from protobuf field string service_endpoint = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setServiceEndpoint($var) - { - GPBUtil::checkString($var, True); - $this->service_endpoint = $var; - - return $this; - } - - /** - * Name of the zone in which the Data Fusion instance will be created. Only - * DEVELOPER instances use this field. - * - * Generated from protobuf field string zone = 15; - * @return string - */ - public function getZone() - { - return $this->zone; - } - - /** - * Name of the zone in which the Data Fusion instance will be created. Only - * DEVELOPER instances use this field. - * - * Generated from protobuf field string zone = 15; - * @param string $var - * @return $this - */ - public function setZone($var) - { - GPBUtil::checkString($var, True); - $this->zone = $var; - - return $this; - } - - /** - * Current version of the Data Fusion. Only specifiable in Update. - * - * Generated from protobuf field string version = 16; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Current version of the Data Fusion. Only specifiable in Update. - * - * Generated from protobuf field string version = 16; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Output only. Deprecated. Use tenant_project_id instead to extract the tenant project ID. - * - * Generated from protobuf field string service_account = 17 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - * @deprecated - */ - public function getServiceAccount() - { - @trigger_error('service_account is deprecated.', E_USER_DEPRECATED); - return $this->service_account; - } - - /** - * Output only. Deprecated. Use tenant_project_id instead to extract the tenant project ID. - * - * Generated from protobuf field string service_account = 17 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - * @deprecated - */ - public function setServiceAccount($var) - { - @trigger_error('service_account is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * Display name for an instance. - * - * Generated from protobuf field string display_name = 18; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Display name for an instance. - * - * Generated from protobuf field string display_name = 18; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Available versions that the instance can be upgraded to using - * UpdateInstanceRequest. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_version = 19; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAvailableVersion() - { - return $this->available_version; - } - - /** - * Available versions that the instance can be upgraded to using - * UpdateInstanceRequest. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_version = 19; - * @param array<\Google\Cloud\DataFusion\V1\Version>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAvailableVersion($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataFusion\V1\Version::class); - $this->available_version = $arr; - - return $this; - } - - /** - * Output only. Endpoint on which the REST APIs is accessible. - * - * Generated from protobuf field string api_endpoint = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getApiEndpoint() - { - return $this->api_endpoint; - } - - /** - * Output only. Endpoint on which the REST APIs is accessible. - * - * Generated from protobuf field string api_endpoint = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setApiEndpoint($var) - { - GPBUtil::checkString($var, True); - $this->api_endpoint = $var; - - return $this; - } - - /** - * Output only. Cloud Storage bucket generated by Data Fusion in the customer project. - * - * Generated from protobuf field string gcs_bucket = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getGcsBucket() - { - return $this->gcs_bucket; - } - - /** - * Output only. Cloud Storage bucket generated by Data Fusion in the customer project. - * - * Generated from protobuf field string gcs_bucket = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setGcsBucket($var) - { - GPBUtil::checkString($var, True); - $this->gcs_bucket = $var; - - return $this; - } - - /** - * List of accelerators enabled for this CDF instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Accelerator accelerators = 22; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAccelerators() - { - return $this->accelerators; - } - - /** - * List of accelerators enabled for this CDF instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Accelerator accelerators = 22; - * @param array<\Google\Cloud\DataFusion\V1\Accelerator>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAccelerators($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataFusion\V1\Accelerator::class); - $this->accelerators = $arr; - - return $this; - } - - /** - * Output only. P4 service account for the customer project. - * - * Generated from protobuf field string p4_service_account = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getP4ServiceAccount() - { - return $this->p4_service_account; - } - - /** - * Output only. P4 service account for the customer project. - * - * Generated from protobuf field string p4_service_account = 23 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setP4ServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->p4_service_account = $var; - - return $this; - } - - /** - * Output only. The name of the tenant project. - * - * Generated from protobuf field string tenant_project_id = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getTenantProjectId() - { - return $this->tenant_project_id; - } - - /** - * Output only. The name of the tenant project. - * - * Generated from protobuf field string tenant_project_id = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setTenantProjectId($var) - { - GPBUtil::checkString($var, True); - $this->tenant_project_id = $var; - - return $this; - } - - /** - * User-managed service account to set on Dataproc when Cloud Data Fusion - * creates Dataproc to run data processing pipelines. - * This allows users to have fine-grained access control on Dataproc's - * accesses to cloud resources. - * - * Generated from protobuf field string dataproc_service_account = 25; - * @return string - */ - public function getDataprocServiceAccount() - { - return $this->dataproc_service_account; - } - - /** - * User-managed service account to set on Dataproc when Cloud Data Fusion - * creates Dataproc to run data processing pipelines. - * This allows users to have fine-grained access control on Dataproc's - * accesses to cloud resources. - * - * Generated from protobuf field string dataproc_service_account = 25; - * @param string $var - * @return $this - */ - public function setDataprocServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->dataproc_service_account = $var; - - return $this; - } - - /** - * Option to enable granular role-based access control. - * - * Generated from protobuf field bool enable_rbac = 27; - * @return bool - */ - public function getEnableRbac() - { - return $this->enable_rbac; - } - - /** - * Option to enable granular role-based access control. - * - * Generated from protobuf field bool enable_rbac = 27; - * @param bool $var - * @return $this - */ - public function setEnableRbac($var) - { - GPBUtil::checkBool($var); - $this->enable_rbac = $var; - - return $this; - } - - /** - * The crypto key configuration. This field is used by the Customer-Managed - * Encryption Keys (CMEK) feature. - * - * Generated from protobuf field .google.cloud.datafusion.v1.CryptoKeyConfig crypto_key_config = 28; - * @return \Google\Cloud\DataFusion\V1\CryptoKeyConfig|null - */ - public function getCryptoKeyConfig() - { - return $this->crypto_key_config; - } - - public function hasCryptoKeyConfig() - { - return isset($this->crypto_key_config); - } - - public function clearCryptoKeyConfig() - { - unset($this->crypto_key_config); - } - - /** - * The crypto key configuration. This field is used by the Customer-Managed - * Encryption Keys (CMEK) feature. - * - * Generated from protobuf field .google.cloud.datafusion.v1.CryptoKeyConfig crypto_key_config = 28; - * @param \Google\Cloud\DataFusion\V1\CryptoKeyConfig $var - * @return $this - */ - public function setCryptoKeyConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataFusion\V1\CryptoKeyConfig::class); - $this->crypto_key_config = $var; - - return $this; - } - - /** - * Output only. If the instance state is DISABLED, the reason for disabling the instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance.DisabledReason disabled_reason = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDisabledReason() - { - return $this->disabled_reason; - } - - /** - * Output only. If the instance state is DISABLED, the reason for disabling the instance. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance.DisabledReason disabled_reason = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDisabledReason($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\DataFusion\V1\Instance\DisabledReason::class); - $this->disabled_reason = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/DisabledReason.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/DisabledReason.php deleted file mode 100644 index 7e63e2a3e63f..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/DisabledReason.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.datafusion.v1.Instance.DisabledReason - */ -class DisabledReason -{ - /** - * This is an unknown reason for disabling. - * - * Generated from protobuf enum DISABLED_REASON_UNSPECIFIED = 0; - */ - const DISABLED_REASON_UNSPECIFIED = 0; - /** - * The KMS key used by the instance is either revoked or denied access to - * - * Generated from protobuf enum KMS_KEY_ISSUE = 1; - */ - const KMS_KEY_ISSUE = 1; - - private static $valueToName = [ - self::DISABLED_REASON_UNSPECIFIED => 'DISABLED_REASON_UNSPECIFIED', - self::KMS_KEY_ISSUE => 'KMS_KEY_ISSUE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DisabledReason::class, \Google\Cloud\DataFusion\V1\Instance_DisabledReason::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/State.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/State.php deleted file mode 100644 index 1a9ad67c6822..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/State.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.datafusion.v1.Instance.State - */ -class State -{ - /** - * Instance does not have a state yet - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Instance is being created - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * Instance is active and ready for requests. This corresponds to 'RUNNING' - * in datafusion.v1beta1. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * Instance creation failed - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - /** - * Instance is being deleted - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * Instance is being upgraded - * - * Generated from protobuf enum UPGRADING = 5; - */ - const UPGRADING = 5; - /** - * Instance is being restarted - * - * Generated from protobuf enum RESTARTING = 6; - */ - const RESTARTING = 6; - /** - * Instance is being updated on customer request - * - * Generated from protobuf enum UPDATING = 7; - */ - const UPDATING = 7; - /** - * Instance is being auto-updated - * - * Generated from protobuf enum AUTO_UPDATING = 8; - */ - const AUTO_UPDATING = 8; - /** - * Instance is being auto-upgraded - * - * Generated from protobuf enum AUTO_UPGRADING = 9; - */ - const AUTO_UPGRADING = 9; - /** - * Instance is disabled - * - * Generated from protobuf enum DISABLED = 10; - */ - const DISABLED = 10; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::FAILED => 'FAILED', - self::DELETING => 'DELETING', - self::UPGRADING => 'UPGRADING', - self::RESTARTING => 'RESTARTING', - self::UPDATING => 'UPDATING', - self::AUTO_UPDATING => 'AUTO_UPDATING', - self::AUTO_UPGRADING => 'AUTO_UPGRADING', - self::DISABLED => 'DISABLED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\DataFusion\V1\Instance_State::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/Type.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/Type.php deleted file mode 100644 index 8258f055691d..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance/Type.php +++ /dev/null @@ -1,80 +0,0 @@ -google.cloud.datafusion.v1.Instance.Type - */ -class Type -{ - /** - * No type specified. The instance creation will fail. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Basic Data Fusion instance. In Basic type, the user will be able to - * create data pipelines using point and click UI. However, there are - * certain limitations, such as fewer number of concurrent pipelines, no - * support for streaming pipelines, etc. - * - * Generated from protobuf enum BASIC = 1; - */ - const BASIC = 1; - /** - * Enterprise Data Fusion instance. In Enterprise type, the user will have - * all features available, such as support for streaming pipelines, higher - * number of concurrent pipelines, etc. - * - * Generated from protobuf enum ENTERPRISE = 2; - */ - const ENTERPRISE = 2; - /** - * Developer Data Fusion instance. In Developer type, the user will have all - * features available but with restrictive capabilities. This is to help - * enterprises design and develop their data ingestion and integration - * pipelines at low cost. - * - * Generated from protobuf enum DEVELOPER = 3; - */ - const DEVELOPER = 3; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::BASIC => 'BASIC', - self::ENTERPRISE => 'ENTERPRISE', - self::DEVELOPER => 'DEVELOPER', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\DataFusion\V1\Instance_Type::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_DisabledReason.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_DisabledReason.php deleted file mode 100644 index 1da6d1a657be..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Instance_DisabledReason.php +++ /dev/null @@ -1,16 +0,0 @@ -google.cloud.datafusion.v1.ListAvailableVersionsRequest - */ -class ListAvailableVersionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Whether or not to return the latest patch of every available minor version. - * If true, only the latest patch will be returned. Ex. if allowed versions is - * [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0] - * - * Generated from protobuf field bool latest_patch_only = 4; - */ - protected $latest_patch_only = false; - - /** - * @param string $parent Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. Please see - * {@see DataFusionClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\DataFusion\V1\ListAvailableVersionsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. - * @type int $page_size - * The maximum number of items to return. - * @type string $page_token - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * @type bool $latest_patch_only - * Whether or not to return the latest patch of every available minor version. - * If true, only the latest patch will be returned. Ex. if allowed versions is - * [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Whether or not to return the latest patch of every available minor version. - * If true, only the latest patch will be returned. Ex. if allowed versions is - * [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0] - * - * Generated from protobuf field bool latest_patch_only = 4; - * @return bool - */ - public function getLatestPatchOnly() - { - return $this->latest_patch_only; - } - - /** - * Whether or not to return the latest patch of every available minor version. - * If true, only the latest patch will be returned. Ex. if allowed versions is - * [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0] - * - * Generated from protobuf field bool latest_patch_only = 4; - * @param bool $var - * @return $this - */ - public function setLatestPatchOnly($var) - { - GPBUtil::checkBool($var); - $this->latest_patch_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListAvailableVersionsResponse.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListAvailableVersionsResponse.php deleted file mode 100644 index 84d6591cac2d..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListAvailableVersionsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.datafusion.v1.ListAvailableVersionsResponse - */ -class ListAvailableVersionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Represents a list of versions that are supported. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_versions = 1; - */ - private $available_versions; - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataFusion\V1\Version>|\Google\Protobuf\Internal\RepeatedField $available_versions - * Represents a list of versions that are supported. - * @type string $next_page_token - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Represents a list of versions that are supported. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_versions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAvailableVersions() - { - return $this->available_versions; - } - - /** - * Represents a list of versions that are supported. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Version available_versions = 1; - * @param array<\Google\Cloud\DataFusion\V1\Version>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAvailableVersions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataFusion\V1\Version::class); - $this->available_versions = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesRequest.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesRequest.php deleted file mode 100644 index ba894d09f34a..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesRequest.php +++ /dev/null @@ -1,219 +0,0 @@ -google.cloud.datafusion.v1.ListInstancesRequest - */ -class ListInstancesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. If the location is - * specified as '-' (wildcard), then all regions available to the project - * are queried, and the results are aggregated. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sort results. Supported values are "name", "name desc", or "" (unsorted). - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. If the location is - * specified as '-' (wildcard), then all regions available to the project - * are queried, and the results are aggregated. - * @type int $page_size - * The maximum number of items to return. - * @type string $page_token - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * @type string $filter - * List filter. - * @type string $order_by - * Sort results. Supported values are "name", "name desc", or "" (unsorted). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. If the location is - * specified as '-' (wildcard), then all regions available to the project - * are queried, and the results are aggregated. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. If the location is - * specified as '-' (wildcard), then all regions available to the project - * are queried, and the results are aggregated. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of items to return. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The next_page_token value to use if there are additional - * results to retrieve for this list request. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * List filter. - * - * Generated from protobuf field string filter = 4; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Sort results. Supported values are "name", "name desc", or "" (unsorted). - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sort results. Supported values are "name", "name desc", or "" (unsorted). - * - * Generated from protobuf field string order_by = 5; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesResponse.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesResponse.php deleted file mode 100644 index 95f50a1e2b08..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/ListInstancesResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.datafusion.v1.ListInstancesResponse - */ -class ListInstancesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Represents a list of Data Fusion instances. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance instances = 1; - */ - private $instances; - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\DataFusion\V1\Instance>|\Google\Protobuf\Internal\RepeatedField $instances - * Represents a list of Data Fusion instances. - * @type string $next_page_token - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * @type array|\Google\Protobuf\Internal\RepeatedField $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Represents a list of Data Fusion instances. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance instances = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getInstances() - { - return $this->instances; - } - - /** - * Represents a list of Data Fusion instances. - * - * Generated from protobuf field repeated .google.cloud.datafusion.v1.Instance instances = 1; - * @param array<\Google\Cloud\DataFusion\V1\Instance>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setInstances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DataFusion\V1\Instance::class); - $this->instances = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results or empty if there are no more - * results in the list. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUnreachable($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->unreachable = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/NetworkConfig.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/NetworkConfig.php deleted file mode 100644 index 6a65391a768e..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/NetworkConfig.php +++ /dev/null @@ -1,126 +0,0 @@ -google.cloud.datafusion.v1.NetworkConfig - */ -class NetworkConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the network in the customer project with which the Tenant Project - * will be peered for executing pipelines. In case of shared VPC where the - * network resides in another host project the network should specified in - * the form of projects/{host-project-id}/global/networks/{network} - * - * Generated from protobuf field string network = 1; - */ - protected $network = ''; - /** - * The IP range in CIDR notation to use for the managed Data Fusion instance - * nodes. This range must not overlap with any other ranges used in the - * customer network. - * - * Generated from protobuf field string ip_allocation = 2; - */ - protected $ip_allocation = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network - * Name of the network in the customer project with which the Tenant Project - * will be peered for executing pipelines. In case of shared VPC where the - * network resides in another host project the network should specified in - * the form of projects/{host-project-id}/global/networks/{network} - * @type string $ip_allocation - * The IP range in CIDR notation to use for the managed Data Fusion instance - * nodes. This range must not overlap with any other ranges used in the - * customer network. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Name of the network in the customer project with which the Tenant Project - * will be peered for executing pipelines. In case of shared VPC where the - * network resides in another host project the network should specified in - * the form of projects/{host-project-id}/global/networks/{network} - * - * Generated from protobuf field string network = 1; - * @return string - */ - public function getNetwork() - { - return $this->network; - } - - /** - * Name of the network in the customer project with which the Tenant Project - * will be peered for executing pipelines. In case of shared VPC where the - * network resides in another host project the network should specified in - * the form of projects/{host-project-id}/global/networks/{network} - * - * Generated from protobuf field string network = 1; - * @param string $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkString($var, True); - $this->network = $var; - - return $this; - } - - /** - * The IP range in CIDR notation to use for the managed Data Fusion instance - * nodes. This range must not overlap with any other ranges used in the - * customer network. - * - * Generated from protobuf field string ip_allocation = 2; - * @return string - */ - public function getIpAllocation() - { - return $this->ip_allocation; - } - - /** - * The IP range in CIDR notation to use for the managed Data Fusion instance - * nodes. This range must not overlap with any other ranges used in the - * customer network. - * - * Generated from protobuf field string ip_allocation = 2; - * @param string $var - * @return $this - */ - public function setIpAllocation($var) - { - GPBUtil::checkString($var, True); - $this->ip_allocation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/OperationMetadata.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/OperationMetadata.php deleted file mode 100644 index 6e092c20d7a7..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/OperationMetadata.php +++ /dev/null @@ -1,349 +0,0 @@ -google.cloud.datafusion.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - */ - protected $create_time = null; - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - */ - protected $end_time = null; - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - */ - protected $target = ''; - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - */ - protected $verb = ''; - /** - * Human-readable status of the operation if any. - * - * Generated from protobuf field string status_detail = 5; - */ - protected $status_detail = ''; - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - */ - protected $requested_cancellation = false; - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - */ - protected $api_version = ''; - /** - * Map to hold any additional status info for the operation - * If there is an accelerator being enabled/disabled/deleted, this will be - * populated with accelerator name as key and status as - * ENABLING, DISABLING or DELETING - * - * Generated from protobuf field map additional_status = 8; - */ - private $additional_status; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Timestamp $create_time - * The time the operation was created. - * @type \Google\Protobuf\Timestamp $end_time - * The time the operation finished running. - * @type string $target - * Server-defined resource path for the target of the operation. - * @type string $verb - * Name of the verb executed by the operation. - * @type string $status_detail - * Human-readable status of the operation if any. - * @type bool $requested_cancellation - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * @type string $api_version - * API version used to start the operation. - * @type array|\Google\Protobuf\Internal\MapField $additional_status - * Map to hold any additional status info for the operation - * If there is an accelerator being enabled/disabled/deleted, this will be - * populated with accelerator name as key and status as - * ENABLING, DISABLING or DELETING - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time the operation was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 1; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEndTime() - { - return $this->end_time; - } - - public function hasEndTime() - { - return isset($this->end_time); - } - - public function clearEndTime() - { - unset($this->end_time); - } - - /** - * The time the operation finished running. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEndTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->end_time = $var; - - return $this; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @return string - */ - public function getTarget() - { - return $this->target; - } - - /** - * Server-defined resource path for the target of the operation. - * - * Generated from protobuf field string target = 3; - * @param string $var - * @return $this - */ - public function setTarget($var) - { - GPBUtil::checkString($var, True); - $this->target = $var; - - return $this; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * Name of the verb executed by the operation. - * - * Generated from protobuf field string verb = 4; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * Human-readable status of the operation if any. - * - * Generated from protobuf field string status_detail = 5; - * @return string - */ - public function getStatusDetail() - { - return $this->status_detail; - } - - /** - * Human-readable status of the operation if any. - * - * Generated from protobuf field string status_detail = 5; - * @param string $var - * @return $this - */ - public function setStatusDetail($var) - { - GPBUtil::checkString($var, True); - $this->status_detail = $var; - - return $this; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - * @return bool - */ - public function getRequestedCancellation() - { - return $this->requested_cancellation; - } - - /** - * Identifies whether the user has requested cancellation - * of the operation. Operations that have successfully been cancelled - * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, - * corresponding to `Code.CANCELLED`. - * - * Generated from protobuf field bool requested_cancellation = 6; - * @param bool $var - * @return $this - */ - public function setRequestedCancellation($var) - { - GPBUtil::checkBool($var); - $this->requested_cancellation = $var; - - return $this; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @return string - */ - public function getApiVersion() - { - return $this->api_version; - } - - /** - * API version used to start the operation. - * - * Generated from protobuf field string api_version = 7; - * @param string $var - * @return $this - */ - public function setApiVersion($var) - { - GPBUtil::checkString($var, True); - $this->api_version = $var; - - return $this; - } - - /** - * Map to hold any additional status info for the operation - * If there is an accelerator being enabled/disabled/deleted, this will be - * populated with accelerator name as key and status as - * ENABLING, DISABLING or DELETING - * - * Generated from protobuf field map additional_status = 8; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAdditionalStatus() - { - return $this->additional_status; - } - - /** - * Map to hold any additional status info for the operation - * If there is an accelerator being enabled/disabled/deleted, this will be - * populated with accelerator name as key and status as - * ENABLING, DISABLING or DELETING - * - * Generated from protobuf field map additional_status = 8; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAdditionalStatus($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->additional_status = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/RestartInstanceRequest.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/RestartInstanceRequest.php deleted file mode 100644 index 907af0135078..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/RestartInstanceRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.datafusion.v1.RestartInstanceRequest - */ -class RestartInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the Data Fusion instance which need to be restarted in the form of - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the Data Fusion instance which need to be restarted in the form of - * projects/{project}/locations/{location}/instances/{instance} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the Data Fusion instance which need to be restarted in the form of - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the Data Fusion instance which need to be restarted in the form of - * projects/{project}/locations/{location}/instances/{instance} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/UpdateInstanceRequest.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/UpdateInstanceRequest.php deleted file mode 100644 index bfa27509b610..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/UpdateInstanceRequest.php +++ /dev/null @@ -1,173 +0,0 @@ -google.cloud.datafusion.v1.UpdateInstanceRequest - */ -class UpdateInstanceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $instance = null; - /** - * Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\DataFusion\V1\Instance $instance Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * @param \Google\Protobuf\FieldMask $updateMask Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * - * @return \Google\Cloud\DataFusion\V1\UpdateInstanceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\DataFusion\V1\Instance $instance, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setInstance($instance) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\DataFusion\V1\Instance $instance - * Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * @type \Google\Protobuf\FieldMask $update_mask - * Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\DataFusion\V1\Instance|null - */ - public function getInstance() - { - return $this->instance; - } - - public function hasInstance() - { - return isset($this->instance); - } - - public function clearInstance() - { - unset($this->instance); - } - - /** - * Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.datafusion.v1.Instance instance = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\DataFusion\V1\Instance $var - * @return $this - */ - public function setInstance($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\DataFusion\V1\Instance::class); - $this->instance = $var; - - return $this; - } - - /** - * Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version.php deleted file mode 100644 index 96841661c8c1..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version.php +++ /dev/null @@ -1,170 +0,0 @@ -google.cloud.datafusion.v1.Version - */ -class Version extends \Google\Protobuf\Internal\Message -{ - /** - * The version number of the Data Fusion instance, such as '6.0.1.0'. - * - * Generated from protobuf field string version_number = 1; - */ - protected $version_number = ''; - /** - * Whether this is currently the default version for Cloud Data Fusion - * - * Generated from protobuf field bool default_version = 2; - */ - protected $default_version = false; - /** - * Represents a list of available feature names for a given version. - * - * Generated from protobuf field repeated string available_features = 3; - */ - private $available_features; - /** - * Type represents the release availability of the version - * - * Generated from protobuf field .google.cloud.datafusion.v1.Version.Type type = 4; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $version_number - * The version number of the Data Fusion instance, such as '6.0.1.0'. - * @type bool $default_version - * Whether this is currently the default version for Cloud Data Fusion - * @type array|\Google\Protobuf\Internal\RepeatedField $available_features - * Represents a list of available feature names for a given version. - * @type int $type - * Type represents the release availability of the version - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Datafusion\V1\Datafusion::initOnce(); - parent::__construct($data); - } - - /** - * The version number of the Data Fusion instance, such as '6.0.1.0'. - * - * Generated from protobuf field string version_number = 1; - * @return string - */ - public function getVersionNumber() - { - return $this->version_number; - } - - /** - * The version number of the Data Fusion instance, such as '6.0.1.0'. - * - * Generated from protobuf field string version_number = 1; - * @param string $var - * @return $this - */ - public function setVersionNumber($var) - { - GPBUtil::checkString($var, True); - $this->version_number = $var; - - return $this; - } - - /** - * Whether this is currently the default version for Cloud Data Fusion - * - * Generated from protobuf field bool default_version = 2; - * @return bool - */ - public function getDefaultVersion() - { - return $this->default_version; - } - - /** - * Whether this is currently the default version for Cloud Data Fusion - * - * Generated from protobuf field bool default_version = 2; - * @param bool $var - * @return $this - */ - public function setDefaultVersion($var) - { - GPBUtil::checkBool($var); - $this->default_version = $var; - - return $this; - } - - /** - * Represents a list of available feature names for a given version. - * - * Generated from protobuf field repeated string available_features = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAvailableFeatures() - { - return $this->available_features; - } - - /** - * Represents a list of available feature names for a given version. - * - * Generated from protobuf field repeated string available_features = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAvailableFeatures($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->available_features = $arr; - - return $this; - } - - /** - * Type represents the release availability of the version - * - * Generated from protobuf field .google.cloud.datafusion.v1.Version.Type type = 4; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Type represents the release availability of the version - * - * Generated from protobuf field .google.cloud.datafusion.v1.Version.Type type = 4; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\DataFusion\V1\Version\Type::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version/Type.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version/Type.php deleted file mode 100644 index 947abd9a8fad..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version/Type.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.datafusion.v1.Version.Type - */ -class Type -{ - /** - * Version does not have availability yet - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Version is under development and not considered stable - * - * Generated from protobuf enum TYPE_PREVIEW = 1; - */ - const TYPE_PREVIEW = 1; - /** - * Version is available for public use - * - * Generated from protobuf enum TYPE_GENERAL_AVAILABILITY = 2; - */ - const TYPE_GENERAL_AVAILABILITY = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::TYPE_PREVIEW => 'TYPE_PREVIEW', - self::TYPE_GENERAL_AVAILABILITY => 'TYPE_GENERAL_AVAILABILITY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Type::class, \Google\Cloud\DataFusion\V1\Version_Type::class); - diff --git a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version_Type.php b/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version_Type.php deleted file mode 100644 index 157a95d524f2..000000000000 --- a/owl-bot-staging/DataFusion/v1/proto/src/Google/Cloud/DataFusion/V1/Version_Type.php +++ /dev/null @@ -1,16 +0,0 @@ -setParent($formattedParent) - ->setInstanceId($instanceId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $dataFusionClient->createInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 = DataFusionClient::locationName('[PROJECT]', '[LOCATION]'); - $instanceId = '[INSTANCE_ID]'; - - create_instance_sample($formattedParent, $instanceId); -} -// [END datafusion_v1_generated_DataFusion_CreateInstance_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/delete_instance.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/delete_instance.php deleted file mode 100644 index f0b5b4bce2be..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/delete_instance.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $dataFusionClient->deleteInstance($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 = DataFusionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - delete_instance_sample($formattedName); -} -// [END datafusion_v1_generated_DataFusion_DeleteInstance_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/get_instance.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/get_instance.php deleted file mode 100644 index 36b534b2257f..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/get_instance.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Instance $response */ - $response = $dataFusionClient->getInstance($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 = DataFusionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - get_instance_sample($formattedName); -} -// [END datafusion_v1_generated_DataFusion_GetInstance_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_available_versions.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_available_versions.php deleted file mode 100644 index e213f47aeac8..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_available_versions.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dataFusionClient->listAvailableVersions($request); - - /** @var Version $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 = DataFusionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_available_versions_sample($formattedParent); -} -// [END datafusion_v1_generated_DataFusion_ListAvailableVersions_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_instances.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_instances.php deleted file mode 100644 index 58d66907ab6c..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/list_instances.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dataFusionClient->listInstances($request); - - /** @var Instance $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 = DataFusionClient::locationName('[PROJECT]', '[LOCATION]'); - - list_instances_sample($formattedParent); -} -// [END datafusion_v1_generated_DataFusion_ListInstances_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/restart_instance.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/restart_instance.php deleted file mode 100644 index 84c34181ef35..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/restart_instance.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $dataFusionClient->restartInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 = DataFusionClient::instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - - restart_instance_sample($formattedName); -} -// [END datafusion_v1_generated_DataFusion_RestartInstance_sync] diff --git a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/update_instance.php b/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/update_instance.php deleted file mode 100644 index efa67fc9ae60..000000000000 --- a/owl-bot-staging/DataFusion/v1/samples/V1/DataFusionClient/update_instance.php +++ /dev/null @@ -1,85 +0,0 @@ -setType($instanceType); - $request = (new UpdateInstanceRequest()) - ->setInstance($instance); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $dataFusionClient->updateInstance($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Instance $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 -{ - $instanceType = Type::TYPE_UNSPECIFIED; - - update_instance_sample($instanceType); -} -// [END datafusion_v1_generated_DataFusion_UpdateInstance_sync] diff --git a/owl-bot-staging/DataFusion/v1/src/V1/DataFusionClient.php b/owl-bot-staging/DataFusion/v1/src/V1/DataFusionClient.php deleted file mode 100644 index 5cc684e64c31..000000000000 --- a/owl-bot-staging/DataFusion/v1/src/V1/DataFusionClient.php +++ /dev/null @@ -1,34 +0,0 @@ -locationName('[PROJECT]', '[LOCATION]'); - * $instanceId = 'instance_id'; - * $operationResponse = $dataFusionClient->createInstance($formattedParent, $instanceId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $dataFusionClient->createInstance($formattedParent, $instanceId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $dataFusionClient->resumeOperation($operationName, 'createInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * 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. - */ -class DataFusionGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.datafusion.v1.DataFusion'; - - /** The default address of the service. */ - const SERVICE_ADDRESS = 'datafusion.googleapis.com'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $cryptoKeyNameTemplate; - - private static $instanceNameTemplate; - - private static $locationNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/data_fusion_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/data_fusion_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/data_fusion_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/data_fusion_rest_client_config.php', - ], - ], - ]; - } - - private static function getCryptoKeyNameTemplate() - { - if (self::$cryptoKeyNameTemplate == null) { - self::$cryptoKeyNameTemplate = new PathTemplate('projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}'); - } - - return self::$cryptoKeyNameTemplate; - } - - private static function getInstanceNameTemplate() - { - if (self::$instanceNameTemplate == null) { - self::$instanceNameTemplate = new PathTemplate('projects/{project}/locations/{location}/instances/{instance}'); - } - - return self::$instanceNameTemplate; - } - - private static function getLocationNameTemplate() - { - if (self::$locationNameTemplate == null) { - self::$locationNameTemplate = new PathTemplate('projects/{project}/locations/{location}'); - } - - return self::$locationNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'cryptoKey' => self::getCryptoKeyNameTemplate(), - 'instance' => self::getInstanceNameTemplate(), - 'location' => self::getLocationNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a crypto_key - * resource. - * - * @param string $project - * @param string $location - * @param string $keyRing - * @param string $cryptoKey - * - * @return string The formatted crypto_key resource. - */ - public static function cryptoKeyName($project, $location, $keyRing, $cryptoKey) - { - return self::getCryptoKeyNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'key_ring' => $keyRing, - 'crypto_key' => $cryptoKey, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a instance - * resource. - * - * @param string $project - * @param string $location - * @param string $instance - * - * @return string The formatted instance resource. - */ - public static function instanceName($project, $location, $instance) - { - return self::getInstanceNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'instance' => $instance, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName($project, $location) - { - return self::getLocationNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - cryptoKey: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key} - * - instance: projects/{project}/locations/{location}/instances/{instance} - * - location: projects/{project}/locations/{location} - * - * 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. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * 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. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'datafusion.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * 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. - * @type string|TransportInterface $transport - * 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 {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * 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 {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * 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. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a new Data Fusion instance in the specified project and location. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedParent = $dataFusionClient->locationName('[PROJECT]', '[LOCATION]'); - * $instanceId = 'instance_id'; - * $operationResponse = $dataFusionClient->createInstance($formattedParent, $instanceId); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $dataFusionClient->createInstance($formattedParent, $instanceId); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $dataFusionClient->resumeOperation($operationName, 'createInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $parent Required. The instance's project and location in the format - * projects/{project}/locations/{location}. - * @param string $instanceId Required. The name of the instance to create. - * @param array $optionalArgs { - * Optional. - * - * @type Instance $instance - * An instance resource. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function createInstance($parent, $instanceId, array $optionalArgs = []) - { - $request = new CreateInstanceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setInstanceId($instanceId); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['instance'])) { - $request->setInstance($optionalArgs['instance']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Deletes a single Date Fusion instance. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedName = $dataFusionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $dataFusionClient->deleteInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $dataFusionClient->deleteInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $dataFusionClient->resumeOperation($operationName, 'deleteInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * // operation succeeded and returns no value - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $name Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function deleteInstance($name, array $optionalArgs = []) - { - $request = new DeleteInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('DeleteInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets details of a single Data Fusion instance. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedName = $dataFusionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $response = $dataFusionClient->getInstance($formattedName); - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $name Required. The instance resource name in the format - * projects/{project}/locations/{location}/instances/{instance}. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\DataFusion\V1\Instance - * - * @throws ApiException if the remote call fails - */ - public function getInstance($name, array $optionalArgs = []) - { - $request = new GetInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetInstance', Instance::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists possible versions for Data Fusion instances in the specified project - * and location. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedParent = $dataFusionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dataFusionClient->listAvailableVersions($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dataFusionClient->listAvailableVersions($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type bool $latestPatchOnly - * Whether or not to return the latest patch of every available minor version. - * If true, only the latest patch will be returned. Ex. if allowed versions is - * [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0] - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listAvailableVersions($parent, array $optionalArgs = []) - { - $request = new ListAvailableVersionsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['latestPatchOnly'])) { - $request->setLatestPatchOnly($optionalArgs['latestPatchOnly']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAvailableVersions', $optionalArgs, ListAvailableVersionsResponse::class, $request); - } - - /** - * Lists Data Fusion instances in the specified project and location. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedParent = $dataFusionClient->locationName('[PROJECT]', '[LOCATION]'); - * // Iterate over pages of elements - * $pagedResponse = $dataFusionClient->listInstances($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $dataFusionClient->listInstances($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $parent Required. The project and location for which to retrieve instance information - * in the format projects/{project}/locations/{location}. If the location is - * specified as '-' (wildcard), then all regions available to the project - * are queried, and the results are aggregated. - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type string $filter - * List filter. - * @type string $orderBy - * Sort results. Supported values are "name", "name desc", or "" (unsorted). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listInstances($parent, array $optionalArgs = []) - { - $request = new ListInstancesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListInstances', $optionalArgs, ListInstancesResponse::class, $request); - } - - /** - * Restart a single Data Fusion instance. - * At the end of an operation instance is fully restarted. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $formattedName = $dataFusionClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - * $operationResponse = $dataFusionClient->restartInstance($formattedName); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $dataFusionClient->restartInstance($formattedName); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $dataFusionClient->resumeOperation($operationName, 'restartInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the Data Fusion instance which need to be restarted in the form of - * projects/{project}/locations/{location}/instances/{instance} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function restartInstance($name, array $optionalArgs = []) - { - $request = new RestartInstanceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('RestartInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates a single Data Fusion instance. - * - * Sample code: - * ``` - * $dataFusionClient = new DataFusionClient(); - * try { - * $instance = new Instance(); - * $operationResponse = $dataFusionClient->updateInstance($instance); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $dataFusionClient->updateInstance($instance); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $dataFusionClient->resumeOperation($operationName, 'updateInstance'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $dataFusionClient->close(); - * } - * ``` - * - * @param Instance $instance Required. The instance resource that replaces the resource on the server. Currently, - * Data Fusion only allows replacing labels, options, and stack driver - * settings. All other fields will be ignored. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * Field mask is used to specify the fields that the update will overwrite - * in an instance resource. The fields specified in the update_mask are - * relative to the resource, not the full request. - * A field will be overwritten if it is in the mask. - * If the user does not provide a mask, all the supported fields (labels, - * options, and version currently) will be overwritten. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function updateInstance($instance, array $optionalArgs = []) - { - $request = new UpdateInstanceRequest(); - $requestParamHeaders = []; - $request->setInstance($instance); - $requestParamHeaders['instance.name'] = $instance->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('UpdateInstance', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } -} diff --git a/owl-bot-staging/DataFusion/v1/src/V1/gapic_metadata.json b/owl-bot-staging/DataFusion/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 93ed216798d6..000000000000 --- a/owl-bot-staging/DataFusion/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.datafusion.v1", - "libraryPackage": "Google\\Cloud\\DataFusion\\V1", - "services": { - "DataFusion": { - "clients": { - "grpc": { - "libraryClient": "DataFusionGapicClient", - "rpcs": { - "CreateInstance": { - "methods": [ - "createInstance" - ] - }, - "DeleteInstance": { - "methods": [ - "deleteInstance" - ] - }, - "GetInstance": { - "methods": [ - "getInstance" - ] - }, - "ListAvailableVersions": { - "methods": [ - "listAvailableVersions" - ] - }, - "ListInstances": { - "methods": [ - "listInstances" - ] - }, - "RestartInstance": { - "methods": [ - "restartInstance" - ] - }, - "UpdateInstance": { - "methods": [ - "updateInstance" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_client_config.json b/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_client_config.json deleted file mode 100644 index 98b1fc8756b6..000000000000 --- a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_client_config.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - "interfaces": { - "google.cloud.datafusion.v1.DataFusion": { - "retry_codes": { - "no_retry_codes": [], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListAvailableVersions": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListInstances": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "RestartInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateInstance": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_descriptor_config.php b/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_descriptor_config.php deleted file mode 100644 index 34fbd52f9e1d..000000000000 --- a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_descriptor_config.php +++ /dev/null @@ -1,142 +0,0 @@ - [ - 'google.cloud.datafusion.v1.DataFusion' => [ - 'CreateInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\DataFusion\V1\Instance', - 'metadataReturnType' => '\Google\Cloud\DataFusion\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\DataFusion\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RestartInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\DataFusion\V1\Instance', - 'metadataReturnType' => '\Google\Cloud\DataFusion\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInstance' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\DataFusion\V1\Instance', - 'metadataReturnType' => '\Google\Cloud\DataFusion\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'instance.name', - 'fieldAccessors' => [ - 'getInstance', - 'getName', - ], - ], - ], - ], - 'GetInstance' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\DataFusion\V1\Instance', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAvailableVersions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAvailableVersions', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataFusion\V1\ListAvailableVersionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListInstances' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getInstances', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\DataFusion\V1\ListInstancesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'templateMap' => [ - 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', - 'instance' => 'projects/{project}/locations/{location}/instances/{instance}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_rest_client_config.php b/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_rest_client_config.php deleted file mode 100644 index ac0819bbf4e3..000000000000 --- a/owl-bot-staging/DataFusion/v1/src/V1/resources/data_fusion_rest_client_config.php +++ /dev/null @@ -1,201 +0,0 @@ - [ - 'google.cloud.datafusion.v1.DataFusion' => [ - 'CreateInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/instances', - 'body' => 'instance', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'instance_id', - ], - ], - 'DeleteInstance' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/instances/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetInstance' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/instances/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAvailableVersions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/versions', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListInstances' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/instances', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RestartInstance' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/instances/*}:restart', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateInstance' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{instance.name=projects/*/locations/*/instances/*}', - 'body' => 'instance', - 'placeholders' => [ - 'instance.name' => [ - 'getters' => [ - 'getInstance', - 'getName', - ], - ], - ], - ], - ], - 'google.cloud.location.Locations' => [ - 'GetLocation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListLocations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*}/locations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:getIamPolicy', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/instances/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/DataFusion/v1/tests/Unit/V1/DataFusionClientTest.php b/owl-bot-staging/DataFusion/v1/tests/Unit/V1/DataFusionClientTest.php deleted file mode 100644 index 795a4020c71b..000000000000 --- a/owl-bot-staging/DataFusion/v1/tests/Unit/V1/DataFusionClientTest.php +++ /dev/null @@ -1,876 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DataFusionClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DataFusionClient($options); - } - - /** @test */ - public function createInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $enableStackdriverLogging = true; - $enableStackdriverMonitoring = false; - $privateInstance = false; - $stateMessage = 'stateMessage29641305'; - $serviceEndpoint = 'serviceEndpoint-676052001'; - $zone = 'zone3744684'; - $version = 'version351608024'; - $serviceAccount = 'serviceAccount-1948028253'; - $displayName = 'displayName1615086568'; - $apiEndpoint = 'apiEndpoint-1381395942'; - $gcsBucket = 'gcsBucket-1720393710'; - $p4ServiceAccount = 'p4ServiceAccount-1554461144'; - $tenantProjectId = 'tenantProjectId-2129337674'; - $dataprocServiceAccount = 'dataprocServiceAccount-493324700'; - $enableRbac = true; - $expectedResponse = new Instance(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setEnableStackdriverLogging($enableStackdriverLogging); - $expectedResponse->setEnableStackdriverMonitoring($enableStackdriverMonitoring); - $expectedResponse->setPrivateInstance($privateInstance); - $expectedResponse->setStateMessage($stateMessage); - $expectedResponse->setServiceEndpoint($serviceEndpoint); - $expectedResponse->setZone($zone); - $expectedResponse->setVersion($version); - $expectedResponse->setServiceAccount($serviceAccount); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setApiEndpoint($apiEndpoint); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setP4ServiceAccount($p4ServiceAccount); - $expectedResponse->setTenantProjectId($tenantProjectId); - $expectedResponse->setDataprocServiceAccount($dataprocServiceAccount); - $expectedResponse->setEnableRbac($enableRbac); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $instanceId = 'instanceId-2101995259'; - $response = $gapicClient->createInstance($formattedParent, $instanceId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/CreateInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getInstanceId(); - $this->assertProtobufEquals($instanceId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $instanceId = 'instanceId-2101995259'; - $response = $gapicClient->createInstance($formattedParent, $instanceId); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->deleteInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/DeleteInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function deleteInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/deleteInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->deleteInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getInstanceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $enableStackdriverLogging = true; - $enableStackdriverMonitoring = false; - $privateInstance = false; - $stateMessage = 'stateMessage29641305'; - $serviceEndpoint = 'serviceEndpoint-676052001'; - $zone = 'zone3744684'; - $version = 'version351608024'; - $serviceAccount = 'serviceAccount-1948028253'; - $displayName = 'displayName1615086568'; - $apiEndpoint = 'apiEndpoint-1381395942'; - $gcsBucket = 'gcsBucket-1720393710'; - $p4ServiceAccount = 'p4ServiceAccount-1554461144'; - $tenantProjectId = 'tenantProjectId-2129337674'; - $dataprocServiceAccount = 'dataprocServiceAccount-493324700'; - $enableRbac = true; - $expectedResponse = new Instance(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setEnableStackdriverLogging($enableStackdriverLogging); - $expectedResponse->setEnableStackdriverMonitoring($enableStackdriverMonitoring); - $expectedResponse->setPrivateInstance($privateInstance); - $expectedResponse->setStateMessage($stateMessage); - $expectedResponse->setServiceEndpoint($serviceEndpoint); - $expectedResponse->setZone($zone); - $expectedResponse->setVersion($version); - $expectedResponse->setServiceAccount($serviceAccount); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setApiEndpoint($apiEndpoint); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setP4ServiceAccount($p4ServiceAccount); - $expectedResponse->setTenantProjectId($tenantProjectId); - $expectedResponse->setDataprocServiceAccount($dataprocServiceAccount); - $expectedResponse->setEnableRbac($enableRbac); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->getInstance($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/GetInstance', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getInstanceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - try { - $gapicClient->getInstance($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAvailableVersionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $availableVersionsElement = new Version(); - $availableVersions = [ - $availableVersionsElement, - ]; - $expectedResponse = new ListAvailableVersionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAvailableVersions($availableVersions); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listAvailableVersions($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAvailableVersions()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/ListAvailableVersions', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAvailableVersionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listAvailableVersions($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInstancesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $instancesElement = new Instance(); - $instances = [ - $instancesElement, - ]; - $expectedResponse = new ListInstancesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setInstances($instances); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $response = $gapicClient->listInstances($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getInstances()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/ListInstances', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listInstancesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - try { - $gapicClient->listInstances($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function restartInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/restartInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $enableStackdriverLogging = true; - $enableStackdriverMonitoring = false; - $privateInstance = false; - $stateMessage = 'stateMessage29641305'; - $serviceEndpoint = 'serviceEndpoint-676052001'; - $zone = 'zone3744684'; - $version = 'version351608024'; - $serviceAccount = 'serviceAccount-1948028253'; - $displayName = 'displayName1615086568'; - $apiEndpoint = 'apiEndpoint-1381395942'; - $gcsBucket = 'gcsBucket-1720393710'; - $p4ServiceAccount = 'p4ServiceAccount-1554461144'; - $tenantProjectId = 'tenantProjectId-2129337674'; - $dataprocServiceAccount = 'dataprocServiceAccount-493324700'; - $enableRbac = true; - $expectedResponse = new Instance(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setEnableStackdriverLogging($enableStackdriverLogging); - $expectedResponse->setEnableStackdriverMonitoring($enableStackdriverMonitoring); - $expectedResponse->setPrivateInstance($privateInstance); - $expectedResponse->setStateMessage($stateMessage); - $expectedResponse->setServiceEndpoint($serviceEndpoint); - $expectedResponse->setZone($zone); - $expectedResponse->setVersion($version); - $expectedResponse->setServiceAccount($serviceAccount); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setApiEndpoint($apiEndpoint); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setP4ServiceAccount($p4ServiceAccount); - $expectedResponse->setTenantProjectId($tenantProjectId); - $expectedResponse->setDataprocServiceAccount($dataprocServiceAccount); - $expectedResponse->setEnableRbac($enableRbac); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/restartInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->restartInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/RestartInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/restartInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function restartInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/restartInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->instanceName('[PROJECT]', '[LOCATION]', '[INSTANCE]'); - $response = $gapicClient->restartInstance($formattedName); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/restartInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateInstanceTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $enableStackdriverLogging = true; - $enableStackdriverMonitoring = false; - $privateInstance = false; - $stateMessage = 'stateMessage29641305'; - $serviceEndpoint = 'serviceEndpoint-676052001'; - $zone = 'zone3744684'; - $version = 'version351608024'; - $serviceAccount = 'serviceAccount-1948028253'; - $displayName = 'displayName1615086568'; - $apiEndpoint = 'apiEndpoint-1381395942'; - $gcsBucket = 'gcsBucket-1720393710'; - $p4ServiceAccount = 'p4ServiceAccount-1554461144'; - $tenantProjectId = 'tenantProjectId-2129337674'; - $dataprocServiceAccount = 'dataprocServiceAccount-493324700'; - $enableRbac = true; - $expectedResponse = new Instance(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setEnableStackdriverLogging($enableStackdriverLogging); - $expectedResponse->setEnableStackdriverMonitoring($enableStackdriverMonitoring); - $expectedResponse->setPrivateInstance($privateInstance); - $expectedResponse->setStateMessage($stateMessage); - $expectedResponse->setServiceEndpoint($serviceEndpoint); - $expectedResponse->setZone($zone); - $expectedResponse->setVersion($version); - $expectedResponse->setServiceAccount($serviceAccount); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setApiEndpoint($apiEndpoint); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setP4ServiceAccount($p4ServiceAccount); - $expectedResponse->setTenantProjectId($tenantProjectId); - $expectedResponse->setDataprocServiceAccount($dataprocServiceAccount); - $expectedResponse->setEnableRbac($enableRbac); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateInstanceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $instance = new Instance(); - $instanceType = Type::TYPE_UNSPECIFIED; - $instance->setType($instanceType); - $response = $gapicClient->updateInstance($instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.datafusion.v1.DataFusion/UpdateInstance', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getInstance(); - $this->assertProtobufEquals($instance, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateInstanceTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function updateInstanceExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/updateInstanceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $instance = new Instance(); - $instanceType = Type::TYPE_UNSPECIFIED; - $instance->setType($instanceType); - $response = $gapicClient->updateInstance($instance); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateInstanceTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Annotation.php b/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Annotation.php deleted file mode 100644 index 8bb8e686441dcc85445203caa734012b4f8e5f95..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6038 zcmd5=OH9<0#NaYiHC*F?cct}N5g zPIldN*}u?Lr@Q`v{($WI7usEaM5p(m$F&WPXjqg51NJ%JcV73Ld(W45JI_0CO)Mf4 z*}8+8V*N;To+GhiTaMMR+G4%eY9U)}SO*=WjqIc-78J3psG?jbsmoZkYxV2~%7}ZG zwbw?eM%(H&Q%&8`+jwkj|ks`h<`f0dfRA-T|(0kSB$P^n1*BMZR0!a z+ikI>x4Q_d56iZCW`md}5(UL>&m&U0!lwX|3U0rJAnYtoo!sqX0oTgee#&<+uT)VVnYf zaw$2)K#2nMr$AFdh)`X18gAvRh@gO-yP z(9Ss$7&z(TqLWB^qsI=ITxpbVfvUf zxWt$U0d9PVCz+%qnXn`ToIvyu?7<=<=%PK6nxUx0Pv=RMgXtqOV97x*oe}wArF%Do zJ1PbmkscG4DHSOg=SaiCwodynA3UIbWka&b6iW7y`dq`ccW5+`HNrP`io(?14nZ2> zTpL72X4PMyhNBVR_DKoq{@hxKQQtzdDHKU{f%;tAg?Yw?4skSj4swJO>CZyMk9s5% zeI7bD1wdPt<{Wj9v=56TPo3}(E(9KGT|8*q1HBQ#gn*b#C}{~Mc94y0M2JJ=CB=!6 zKaXfPj!CO9Q?~2_HsJ>)qk&{pdIVGa*%dZn@(?2%4b;W3V>m)UFdPY@>I0i3V%&5cGTkxqs1hDXHB@);~}w)cawBmYGR z(7=HK_%p1F+%!y4`%qKUZKO*@nDmbIMP=G0Fg%=m{I7y_Fo*5^#pBjnsn)x2wXhw%J}~afz$*cNRj{O#m{`J zLpEQQt@+Pr7UM8iHO1BS@T6xjGx!;8Jq^odn}sMDCJtVMwY5Ww3=={YBOlUrnfoCr z%9t<%lX&e$UV2^pv>#iIujgSVaKhazEW={9j2CiQwWO4_s`6wzFKbWA)ry=i-7m?7 znR9rxF{xDK?X0S7&y1~q1#=t-X}p9&SOJm8k;`i7G5$3SRhEmGYe$}m5a5bZEz$p? z>pzXdbbzelr-E=5u5h60Ze`H4YjCynI9rsp{8qMF#Rlh@AAuI8!7ehPobsexD3yy^ zPI;InbFNa&fUl6xrURZZQ_<{uF^ITy!;>#*D>RghIIOp?xt z#e~Z+&&1>%l0NRc3F5gbKUGHm9>eCi5%5PJOfg-(RE4MY=>z(j{_|ERna|b#&5Q zBER-zYVM|)u9`im8s0V2t@Yp06$X{bP^?Ub2g_t!vHAqP65PDuuQxwpYg}&Yd*a5I MO0wnaD|iL)FO}WR8vpinternalAddGeneratedFile( - ' -´ -;google/cloud/datalabeling/v1beta1/annotation_spec_set.proto!google.cloud.datalabeling.v1beta1"¦ -AnnotationSpecSet -name (  - display_name (  - description ( K -annotation_specs ( 21.google.cloud.datalabeling.v1beta1.AnnotationSpec -blocking_resources ( :oêAl --datalabeling.googleapis.com/AnnotationSpecSet;projects/{project}/annotationSpecSets/{annotation_spec_set}"; -AnnotationSpec - display_name (  - description ( Bã -%com.google.cloud.datalabeling.v1beta1PZIcloud.google.com/go/datalabeling/apiv1beta1/datalabelingpb;datalabelingpbª!Google.Cloud.DataLabeling.V1Beta1Ê!Google\\Cloud\\DataLabeling\\V1beta1ê$Google::Cloud::DataLabeling::V1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/DataLabelingService.php b/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/DataLabelingService.php deleted file mode 100644 index 728a4bece9927f30c8a2a1a48e551d47d9e5ac75..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 17166 zcmds9S#KNH6%OSsy7D5A6j`S0gqb+8EXiaf+lfP2cDPw)B8!SdJ8{Z_9g-ty5|YDk zhKilQKvDD|3EGzyDA0!hZP5m8fTBRxhb}+BT^<^s1zfZ!(B&aTfxZ>!Q_tOI?r?_G zB}D^4{bHMQ&$(y$&bjBFGvuW!jjaZHBC@2{^`>U)l}PDM#NN^)jizavWwRP7wKg{N zW~6M^8b(!bMkA4QF0zu#M>6Sb{&66+%vQ6k$0M7jxmnd?<*M1L#44JtRke~{HR_wO z?YWX}YjfnoBLB2#>CJ7UtVhXC2-UTkZZ)*B9$8vVUWfIVMPZ3BEu=8hLRw&2xH*@^ zOcxL;S2fFu;D^g>$92jYy^SL9r_m}^jdH}YH5>jqWmrX{ZrFxaHQoY!7b6>5)zX2F zf9*!AUbYRh9>D~;dRd=36QMlu+EWb^?6Vl*Lat(yfw>CVx~(_sTD6eYt#Z?7*k*GT zmd4|oy6qSme=>E3ZHw6%8<8n0V?6E?axr2zTe`S=B+}IFRG4*uYU+ zEU~a<3yup5nk+WiqXqVe>>Hf+H7Dy7Er>u!{Cwls&cs*~mtcNp0^JEFCgC%^&=g-Y zON{Qy&U9NiE{cMFWfB>T!MU9o7%u!7(G!fQ>S8=*Iv8h*POwGf=!6p|rehSdhx{OR z9#WUq0IPI``hEzFr2I`j%T`ioe?w~mFeXEh(A049++Pwy|4p1lGsL^x z^Psb~36%g90?=edp*n~`XuPJEZRL4%fH`e)2)K;QPqUR>uo-27B=^9M>Iyo#q}y$> zJ%{$<5`jrJLnM0=J%P7!klrQ{DqvD0dDWWf?)Q6q)lFHqH~& zM$v3H)UtC{uQ2#3F2XR97{Xpehs>5Om54vApLN#;}4v8Txd%_y#%>nB?9q21rq62|6QcaFu+qA(b^-Rs=YNspoX0+9NR5c(9>s(p`7lHuPCp_3hCWFE*N#TQrH z6Xzs6(XM@GkCf3#njPCo2I-V9>_x% z(3Wsb;hV9;ghu?ehm;#=ykxfO6{w$!4YPWObH@QcGJipWdyxM)l4FPV=Ys>v9i9JNoB8Q zGwIQX6a^hlEhpC3;s2>bKAT$^4Jo7OU@~`OC7oSaDkgKUj1DQs(IdIFY-S~&Ny8_? zqy5TJbjbN+HMe|gbdPcnJ&gagoL$L`?#0~JGfUTjnDXD397TtlwAN%cRR6q>g~3gu zqMJe(Y~%m$It&Qc4q@SDwessY z)I2fqtORN(?>wV-SYJg4^=*g?&X9(LOktG4WDcMIr&titW9(3%uPV~=-vQ;e{U}uCE=QfN}S_cLtz^i=H0UV zf&@Y^&kpF`Kqtu-;BmvgQ-pd1;1_L)o$1CwKLg-Q26k$~#gbHgI z^Qaw2d*mh>V`VIkMcxo&x7+g)(dZM8p7|wo!o5ZW$u71}E|3db44v(EVe@UIe&{XI z-CZ024a7w5g?Besxi5i3g&T!OSO%pvG#=m!4y(SL(fL-Pqenfr3RfT(Ujy*bcSC5B z;#ladyE_b^!FLUf2z|?*`Z7+lpJMhVdIT^VAm^gz)*B;eJ%b9TyTMgpquxT3)Yig> z+y=Yl{jCr>hH)jZ{v^Wx4x02!$#9>>tu@CN9Pcs}q@Z+Xr03B%xYZp)am!!wcr{AA zI)$F<=2Vvn?&40a>sqtC<$mZG{&L&F)g$u(9a*>0@c;>#(UWMzolS6?pOr}XuDYE~ z{^byQjBQQN#uUu!wWeV~7nz%Xw>I)LwQ*(+Y-+nbO7)LJDAHLdW|k%zW5+oZrjE?4 z!*)Z$JUi_WWkoW)pWjiZH9Rx1g3LE66B9ZoI*GDledk znpx4S#WEScR5&XOvZ!oxpYc+^9YSH6=v{!oz?XY_ASZDW?SX+9OYu)jIKv|fP4ZA{ zhHo?=$aT*{F6VW0Sa(Ktc>Ko9+TU)&ghGlM2Y!fx{`H%kgm7!_%N$35px9RYB5uyyY)vVa`UGhc%o?ga7 z)AtjH=>jtT!g4|>g&^*@*fIsTySyKn&l8yorxihHJXID%b|ePr?uKY5D4r1ps zK`rGOo=`f!ZV?p;xU4dc@zPOzsfz)Ecd_>U#35#CI-6FYBYcR)F*ml1C>{!~!vxpe zNv7l-8kO62x;NYY8!+I`jTIRTxXZarC%H_*YZFoD)gbkYA!5D@>eDV(ySP1WICE?Q z+oO2xtT>Fmmx!Yit{BcvkcsKsKIkETsZn`v2qAamETyu$TvFu^dQ@3=M&Lx{8KN?~ z9J_PuSqi6F&*+&L!xb>V7y%C*WBf3LMp#heVXz`IeiGJmbM!KcRi7ttIH%0Xz=0$L zGN%?Y!fzm+c%YJJQaRT{!6lcOGPDu0q>%Ni;mZkPI&(Gg<%f@;AqZAwEg$#Y1DW=4 z03Fw@pSi4hji|MtJSXKH2ctYW3tswHh>r8y)v}Z;JYnpRzgorIQeyoag9E##ZwBic_xe!1dk6 z6W0f#@5doDOiY32Rfsb!7^1 z-UxV=B$BI2+Eu-CaTD`pk=S%hXY&-2I!DOS&+5iMvC5b2C13e+0b@UEkwFJ=A{y1Dc!#G==2%PR?q9N&SKt1aVw-^S|8MCJ2p%=M^G<-1%_ zS73U{3bQoD91V}1DUKXF6s`ao=q$sRnK&d9C7$Tj&_B`jPT%IVhW9jVjuU(~RdEUL-2dD1yrEK_sXphR<(9@M;Q#k07_D#3eF8I}sOM#U;!n2bJRu4igjJeay=;={a}>yqGvJAa!Oc^%{qw=8B3k_Oq!0m`qS8$h$2 zi&7Y6C^FrE06K1fo_pbHifH?^I@3j4DDIs35eP|(Ao!XM{vOlpYasQ1K%0O8l$16B zbp2~%5^a{}J~3{+7F*_?q1>qK6^>G31)ljsNi3&{9PitW!nua z9*e#C=9_H~V;a1aK!11PY@@2#8)mbX{A&n33GY+veB`W#Ud_@bDE;;%`7Y1 zO$_7^f5d@*-Y6}ILN`hu4n4j^ez75%BHu&CJz3Jq!78y|Y`DkQ6xh!?kl%ISs|xVL z4&>J&J{~$nS;gaoS3E8internalAddGeneratedFile( - ' -Ñ -5google/cloud/datalabeling/v1beta1/data_payloads.proto!google.cloud.datalabeling.v1beta1"a - ImagePayload - mime_type (  -image_thumbnail (  - image_uri (  - -signed_uri ( "# - TextPayload - text_content ( "S -VideoThumbnail - thumbnail ( . - time_offset ( 2.google.protobuf.Duration"© - VideoPayload - mime_type (  - video_uri ( K -video_thumbnails ( 21.google.cloud.datalabeling.v1beta1.VideoThumbnail - -frame_rate ( - -signed_uri ( Bã -%com.google.cloud.datalabeling.v1beta1PZIcloud.google.com/go/datalabeling/apiv1beta1/datalabelingpb;datalabelingpbª!Google.Cloud.DataLabeling.V1Beta1Ê!Google\\Cloud\\DataLabeling\\V1beta1ê$Google::Cloud::DataLabeling::V1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Dataset.php b/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Dataset.php deleted file mode 100644 index f43e84d696bcd79cb33c601aab7243403ed640fc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5687 zcmcIo&2ke*5RNPZR?9YK`7@?cEW#8f0Vy^`LDu|~WDBDNu!98&M3t@8Y9uzSb~n2t z3WaiRIph&?%`s2GDTf^L5;>&Gw>&}8Ju|zKjSLGRT&!BAzv=n9`|F;$b~AVqz!`mw zc`URzYw69t&Yv(n2z~C`zNa;+wF9j{Y*w%BCcS`;56#)|?Qz_Yq63M`xHYa5ljxPputYXYXR zLNJZhA(+O)#R|bJ1K6$=MLPW_!odsB@n6tux{j?!+~W9W-ib`dbGT!<&i8n#>w4RA zBZjuGu5I@`n>)Uzlfk-YvxW1z#H6+JfsZU)*JH;vh!`ZLQS&$pJH%Nrbh#rN7y zCp~hKBXtK;oLk*sw5`aki#HsVN##~6Nt|0)Yzs-KDe&juUHPj|DQD z6(38Gw?l?nY7+eHIDX78%@yU|awFWkn52eQg(=4idR#dh&F<5)Xi|(#_6}XKMs_kg zwK>q5u5Uj@#Wh1E0nzM!#L8*M;h^gKR$0R74u>)Yi!aArqZNJp)}iHa!t zrI?Si$lABe=27W|`n44cI({Mq4DeRr?=0kpy}AukoIU4eSLr)CM0}J|9IlRbaa*|k zfmQ+N*pVrT2x!SU6WGcG?3b}9oQ28ZSZPOL%C)>s&+0Htww9`)!Y6QS^ak27n8tqH z?YZ1Bg*=I>n&GBCN`#S0bQ9AiWBcu zxB}BVch@ukU!2T*ElrDXWYiAY2{@$8mG=os;jb~6pwz9QhGw6OehT(Iv)mpN`jR!qu4W3qOu+2!(Ru?Z0xUYV&H=*FRj$28*rA(3T* zR)@n8>vWkXZ*MW89CyTX3o#A9LUZ@v_iH%rH)+MWF?qq7f zN)yVFxADqJIH8n_@*`w8)kiV)g+H=zKuOF0IIGBXPjgWtk_HpTE3=AB>;F2dP+J^O z65k`!v_++-^vd&7X1n}j=Jj{NnAvaMW6vou*&eVVsb9l0(MMm(;ZxjoPQcOCa=mQU zA8l042lqBNsw=fywd(532U-sH)$W$psxuk-`LMQHU7s1#CSbf?{i;4QuFb&YTJ>J_ ze)*0`5HtHLe`eq;4jXSy^o`8pn!Jjut32I~JH8m_#4tinop@~?e(j9E2hHW-W*#(u z9Xq`y9y*KS?X5^to@kW_QdAF}zsGAD>NQk6hsLWK_#P^rRkz3HC6r+ZEW;QEGYqw? gxgUeY{Y&SPN2Lq$wQ=Zia?giJu~NPvZowA7zok`g5&!@I diff --git a/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Evaluation.php b/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/Evaluation.php deleted file mode 100644 index 900dc2ef5fa5ef3474b2c5edb9aa03b754218b19..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3375 zcmb_f-EJF26t358eoji0ENNI-6`hzsQv_?-B?vZ6t2ha1P)n>fs!(OLTCc~>hV{;B zcQ#F^{17|?ckm{>0T)~$aZ!m|uDIaL>~B(sxU{*+dNkiRXTI}0cklZLK72rSs7C{f z(=O?p5Pm?3A27~r=8{g->(PMNY~VXC4Rk`b_Q*GT`(%4-cYg_?A&UZ=8l=xy-=#I% zWl^`*wYcS49qKw>zjjpbP;S+0^vH4}i#yEIB|U&=4QS|FHYGc)<|EuBaP1w*)ZP?K z?X3b+`)R!?nAQMn*9t?joiV}-Ao%A;9oMl*$nhAPEIXm;cn)_g*ZBeOwoZDM8&ZV7 zy0;g3wlIwdz@BH*mD?od6nmF_hFYwX)V7w82c>E6dYlHH<+itIXa|nZSq*d8#-Oz_b>qCKtX*tMjxj^j&JaFt#yCQL)r3anwp@R8X zfdp3l8fFXn@)MtG6G(ThQ6GaY&y{@ysyAREv5t04htq*+v&iGxBoda5?_X{lz(=P7 zC)V5YolwW3Tg$~&@1a_U)aGIBMe;S2g%*8}OM(QyhJ`YVtGP16>W?Lu%jptd9m35H z8q~!?ZFbnPnFCDbi;NFtWXv?~k8$^A!qjBP`9XUz&4WwLd6+$-0aj+qO~|XOaO1x~ z>UDU>VUfuX0vaALw=0cNs=t+BK0hJ#+cQ{{eZlGB5yEyejRq0iGmS6CxWcArEEz$< z{NR%M9cZj0)Hl17@&nV3f}=QH zXBr=mab_#n6bSVp%!$;FLTS2%p?;hsd1DL~5iSz?NFu9GVR7_j-ptDCpJkX#Ek2!x zqRu6;_<{ei|_*^-v%hV!#|rXBG)pYToy%7Q5WE93YM#)aw(?> zR<$X)c7|Y8n;t>1s)1Oo{-eOGxNjk-u=|t)_8groH2-`I&Cd|%kJ0X!9roM$u>tXUv(39!@*K|)ic>>5cK)S1q xj{y0cc&RMMRE8nB45LV97|FKIgq$(%+{z}tPvZHyFpi%)ip!nx)I5YCz`vEjY3%?2 diff --git a/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/EvaluationJob.php b/owl-bot-staging/DataLabeling/v1beta1/proto/src/GPBMetadata/Google/Cloud/Datalabeling/V1Beta1/EvaluationJob.php deleted file mode 100644 index b463eb4bb7b7d05278ce9a038bd0102eef4ab704..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3264 zcmb_e+iu%N5RH8I&@ODchE@3?Yc)aaBB5#p4N}@}pj&LEsVrD>(G~(&idxB=QY1?* zjktk7p+C}3>1Q-=`HIdiNnKzoR*UFK)Yk|ppOV^XlT^yp<_?+$Zs=Q7Cq38g*)(U_ZrI6nOm5m{ zo7&9jv;{p9Y?3QF2@_{(u*SZR=Q~wMqi5RUScW z{kUHgXa@k6Z3Y3U3{YRWZFmO+e_q(OnMDGQ-YoKf1qO2%XQs{mz)w6PUDFOIBHX;& z4IN8FNQA+uW6|9`5@CwF4?GuBazv8w>LN>+p;p!5)OSp~Ri=UEGmpD|9k1$okMcoo z#hcx|*sXwLU9ua+sOvX^JR;l=>8N)?e9A-LIgoJ+fa}4()-A~^c&v3sV}A7E2Mz6S zvznZ8$wNT7{wc7Aw0#n|ldx|(1;=p(<*rk5oi6K5k31l<$*>x^+4rWmJ@c$q1Kozf z?KZM#o_xpR5-D^#gNk^GEwww~P%!!k-mk;6|JO_EPGqOa9@IvAP>Xvole-&Q*dfbN ze`fM`8w~q8ws~>4&4u90Fb9MgmSijjxE}*ZiNOBK@r0K6!d862_pF@gpfHFIvj5D% z>aes>5!4l!6B3h7k<{+8x&cZjZc!|g^o)F2fq4N!)3f;aS^k+8p?@Tg+L#Yb&`;Gh zSPHBQ+6ir%o|C|vu-bP!)HW`u9|(W*^7T1v4s#~7F#h`V0v;>>-G5Z=>NaeQBsB1- zWgw5~Md>pO87as{p9KM`veEP1(CHW`GW;UFgm;$ILs&97r+tqH>18sDp?oz(DhiQ_ znghl1DJH@YY^6bdOC|wGsMH1>mTka%l((c28Y}V@+L9?Xh^M)R~@$A>w+{h?sM-dOENY?>YmG#q2O zG3wMj2KI(pJjlI^|6Pv^Dl8y87$@sG`{yETjG@E?Sg_6dW{(B&m#^!aj9>AKA;q)z^ z5W1)jC4VplcoRV;L|%p!=6E6cki9NDQpsymfL4WB6slT-^$|W|DAC7C{^=A@L*8P% zpJ8i)7)d!$^3SJ0y>s;t;aFm61@o3te}(OllnOmEan&2} zv^q8UW8oGAMig`ATiBWuwgR)5lvtiuVP33rG!kZg=6R~P1NU$6<5Ns(kOY|h3DT21 zqlnDYzRB#^!4r7cXE=B)i+bE_W3KvC3?dY0(YT&ZEhd#(R8%UrklC^tO3%&Ni_~TzQJI8X>)=Fa4*2*~iU&o8P7O&cWCwE%$J}wu*te za=G7sn0XLE>AJ+y^-(ZgkFT{CJXr@j&go_#`X#tspm!gn%?ASGCh;3peLqVW9OK0UkmV{19 zF`e*7c;t;2egS`gXMO-Pyzwj8J4v=f9q>%alcU@FcK6$F_x8g_(OHD<;wBAfOcLti z{s<>$6i0EGgih$=emWS?7(3xGVm^&^jO!iT?wGhyZ<(8Lm4|8UPy>5m==rqb_+jc+ zT#^u<^r_DRuX4WIrwQ4uoTWn&*dz$Tgd{8sY$pr`%+sYWgaR_8JR%Oo&2H@oZU_*o zDPgTc0c+K#V6D^Lnt0oM&m7E!V+U_BZnJ1Ez{l*Xl8<*EvON2$>yDFs4D#6-hbMyFMn5g1 zM=z)wbu$CdrSSA=;pw^X);Dq=QfN?}ikl~qNl*K|gjQ#&M=hg87I5HQYM`uOW#>k1 z;g4!beH(4$N~W$YymFe@F5{6;Mz)Z0xim4pkKUMJoGSy!EH4zcif}1A$M)hdjmj@i zPS(*)p9Ee?JPNJj((<)SXEBXH;{=YL2`jtodB3{U*c<@A+-ivx^UhN{n6ZULuON=v0